by Vicky jadhav (VJ) (8 Submissions)
Category: Graphics
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Sat 12th June 2004
Date Added: Mon 8th February 2021
Rating: (1 Votes)
Draw points on an Empty form
and then you Make Two Manu Commands 1st one is File (Exit) 2nd One is Graphics (Draw Points) and (Clear)
Ok And Enjoy the [email protected] Is my ID Write Me think about it and Feed Back To me okeys Friends.
Option Explicit
Dim w
Private Sub Form_Load()
w = 0
End Sub
Private Sub mnuClear_Click()
w = 0
frmpoints.Cls
End Sub
Private Sub mnuDrawpoints_Click()
w = 1
End Sub
Private Sub mnuexit_Click()
End
End Sub
Private Sub tmrTimer_Timer()
Dim R, G, B
Dim X, Y
Dim Counter
If w = 1 Then
For Counter = 1 To 1000 Step 1
R = Rnd * 255
G = Rnd * 255
B = Rnd * 255
X = Rnd * frmPoint.ScaleWidth
Y = Rnd * frmPoint.ScaleHeight
frmPoint.PSet (X, Y), RGB(25, 100, 50)
Next
End If
End Sub
Private Sub Command1_Click()
Label8.Caption = "Eienstien identified the no. in your mind as: "
Command1.Caption = "Play again!"
w = 0
Text1.Text = ""
Text1.SetFocus
End Sub
Private Sub Command2_Click()
Timer1.Enabled = True
Label10.Caption = "prosecing"
End Sub
Private Sub Command3_Click()
MsgBox ("perhaps your calculation was not correct!Try again")
End Sub
Private Sub Form_Activate()
Text1.SetFocus
Label8.Caption = "Eienstien identified the no. in your mind as: "
End Sub
Private Sub Text1_LostFocus()
Command2.SetFocus
End Sub
Private Sub Timer1_Timer()
w = w + 1
Label10.Caption = w
If w > 99 Then
Label8.Caption = Label8.Caption & (((Val(Text1.Text) + 3) - 22) / 2)
Timer1.Enabled = False
End If
End Sub