Another Games


‘add 1 timer and 2 command buttons
Dim wkday
Dim mnthday
Dim mnth

Private Sub comm2_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Randomize (8)
comm1.Visible = True
comm2.Visible = False
comm1.ForeColor = QBColor(Rnd(8))
End Sub

Private Sub comm1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Randomize (8)
comm1.Visible = False
comm2.Visible = True
comm2.ForeColor = QBColor(Rnd(8))
End Sub

Private Sub Form_Load()
Me.Height = 4500
Me.Width = 8500
Me.Left = 1800
Me.Top = 2000

wkday = Weekday(Now)
mnth = Month(Now)
If wkday = 1 Then
wkday = “Sunday”
ElseIf wkday = 2 Then
wkday = “Monday”
ElseIf wkday = 3 Then
wkday = “Tuesday”
ElseIf wkday = 4 Then
wkday = “Wednesday”
ElseIf wkday = 5 Then
wkday = “Thursday”
ElseIf wkday = 6 Then
wkday = “Friday”
ElseIf wkday = 7 Then
wkday = “Saturday”
End If
If mnth = 1 Then
mnth = “January”
ElseIf mnth = 2 Then
mnth = “February”
ElseIf mnth = 3 Then
mnth = “March”
ElseIf mnth = 4 Then
mnth = “April”
ElseIf mnth = 5 Then
mnth = “May”
ElseIf mnth = 6 Then
mnth = “June”
ElseIf mnth = 7 Then
mnth = “July”
ElseIf mnth = 8 Then
mnth = “August”
ElseIf mnth = 9 Then
mnth = “September”
ElseIf mnth = 10 Then
mnth = “October”
ElseIf mnth = 11 Then
mnth = “November”
ElseIf mnth = 12 Then
mnth = “December”
End If
End Sub

Private Sub Timer1_Timer()
Me.Caption = Time & “, ” & wkday & “, ” & mnth & ” ” & Day(Now) & “, ” & Year(Now)
timelbl.Caption = Time & “, ” & wkday & “, ” & mnth & ” ” & Day(Now) & “, ” & Year(Now)
End Sub

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s