EC Lim
March 28th, 2001, 11:45 PM
I would like to know how to setup a coordinate system in picturebox control to solve mathermatics question. Example a coordinate system with X-Axis range from -50 to 50cm and Y-Axis range from -50 to 50.
Regards
dhstraayer
April 5th, 2001, 04:56 PM
Create a project with a default-named picturebox and two labels. Paste in this code:
option Explicit
private Sub Form_Load()
Picture1.ScaleHeight = -100
Picture1.ScaleTop = 50
Picture1.ScaleLeft = -50
Picture1.ScaleWidth = 100
End Sub
private Sub Picture1_MouseMove(Button as Integer, Shift as Integer, X as Single, Y as Single)
Label1.Caption = "X:" & Str$(X)
Label2.Caption = "Y:" & Str$(Y)
End Sub
Dave Straayer
Varatouch, Inc.
EC Lim
April 9th, 2001, 01:37 AM
Thank you.