vb中pset函数的使用例子。
展开全部
画点方法Pset
格式:[容器.]Pset [step](x,y)[,color]
实例:
Private SubCommand1_Click()
Dim i As Integer, nAs Byte, x As Integer, y As Integer
Dim r As Integer, gAs Integer, b As Integer
For i = 1 To 1000
Randomize
n = Int(Rnd * 60 + 10)
x = Rnd * Form1.Width
y = Rnd * Form1.Height
r = Int(Rnd * 256)
g = Int(Rnd * 256)
b = Int(Rnd * 256)
Form1.DrawWidth = n
Form1.PSet (x, y), RGB(r, g, b)
Next i
End Sub
格式:[容器.]Pset [step](x,y)[,color]
实例:
Private SubCommand1_Click()
Dim i As Integer, nAs Byte, x As Integer, y As Integer
Dim r As Integer, gAs Integer, b As Integer
For i = 1 To 1000
Randomize
n = Int(Rnd * 60 + 10)
x = Rnd * Form1.Width
y = Rnd * Form1.Height
r = Int(Rnd * 256)
g = Int(Rnd * 256)
b = Int(Rnd * 256)
Form1.DrawWidth = n
Form1.PSet (x, y), RGB(r, g, b)
Next i
End Sub
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询