Printer.PSet 方法 (Single, Single, Int32)

在指定的颜色打印单个页面。

命名空间:  Microsoft.VisualBasic.PowerPacks.Printing.Compatibility.VB6
程序集:  Microsoft.VisualBasic.PowerPacks.Vs(在 Microsoft.VisualBasic.PowerPacks.Vs.dll 中)

语法

声明
Public Sub PSet ( _
    x As Single, _
    y As Single, _
    color As Integer _
)
public void PSet(
    float x,
    float y,
    int color
)
public:
void PSet(
    float x, 
    float y, 
    int color
)
member PSet : 
        x:float32 * 
        y:float32 * 
        color:int -> unit 
public function PSet(
    x : float, 
    y : float, 
    color : int
)

参数

  • x
    类型:System.Single
    指示点的水平坐标的Single 值打印。
  • y
    类型:System.Single
    指示点的垂直坐标的Single 值打印。
  • color
    类型:System.Int32
    可选。指示 RGB (红色、蓝色) 颜色的Integer 值指定为点。如果此参数省略,使用当前 ForeColor 属性设置为。

备注

打印的点大小取决于设置 DrawWidth 属性。 当 DrawWidth 设置为 1 时, PSet 在指定的颜色打印单个时间。 当 DrawWidth 大于 1,则点在指定坐标为中心线居中。

点打印的方式取决于设置 DrawStyle 属性。

当 PSet 运行时, CurrentXCurrentY 属性设置为参数指定的点。

备注

Microsoft.VisualBasic.PowerPacks.Printing.Compatibility.VB6 命名空间中的函数和对象是提供给用于将 Visual Basic 6.0 升级到 Visual Basic 的工具使用的。大多数情况下,这些函数和对象可再现 .NET Framework 中其他命名空间的功能。只有 Visual Basic 6.0 代码模型与 .NET Framework 实现有显著区别时才需要这些函数和对象。

示例

下面的示例在一个指定的颜色演示如何打印时间。

Dim Printer As New Printer
Printer.PSet(500, 500, vbRed)
Printer.EndDoc()

.NET Framework 安全性

请参见

参考

Printer 类

PSet 重载

Microsoft.VisualBasic.PowerPacks.Printing.Compatibility.VB6 命名空间

其他资源

打印机兼容性库

如何:使用打印机兼容性库修复升级错误 (Visual Basic)

部署引用打印机兼容性库的应用程序