VB的picturebox怎么画函数图像y=x^2+2*x啊,
来源:学生作业帮助网 编辑:六六作业网 时间:2024/12/23 07:20:03
VB的picturebox怎么画函数图像y=x^2+2*x啊,VB的picturebox怎么画函数图像y=x^2+2*x啊,VB的picturebox怎么画函数图像y=x^2+2*x啊,Private
VB的picturebox怎么画函数图像y=x^2+2*x啊,
VB的picturebox怎么画函数图像y=x^2+2*x啊,
VB的picturebox怎么画函数图像y=x^2+2*x啊,
Private Sub Command1_Click()
Dim x As Integer
Dim y As Double
Dim startX As Integer
Dim startY As Double
Dim nextX As Integer
Dim nextY As Double
startX = 0
startY = 0
For x = 0 To 100
y = x * x + 2 * x
nextX = x
nextY = Form1.Height - y
Form1.Line (startX,startY)-(nextX,nextY)
startX = nextX
startY = nextY
Next
End Sub
我在窗体上画线,没在picturebox画,改成picturebox就行了