I have a splash screen and i am wanting a moving timer on it so when i play the program it will display "Program is loading" and then " . . . . . . ."
THis is something i have never tried before and hope you could help!!!
Private Sub Form_Load()
Timer1.Enabled = True
Timer1.Interval = 1000 '//This will regulate the speed of events
Timer1.Tag = "-1"
End Sub
Private Sub Timer1_Timer()
Dim i As Integer
Timer1.Tag = Val(Timer1.Tag) + 1
If Timer1.Tag = "0" Then
Label1.Caption = "Program is loading"
Exit Sub
End If
i = Val(Timer1.Tag)
If i < 8 Then
Label1.Caption = Label1.Caption & "."
Else
MAINFORM.Show
Unload Me
End If
End Sub
Last edited by TheBigB; Mar 3rd, 2007 at 06:39 PM.
Thanks sessi4ml it works like a beuty on my main screen the timer and exit button well thought out. On the other hand TheBigB, it doesnt work, it displays in a label Program loading but not the .... and it doesnt hide my splash and unload mainmenu.
Private Sub Form_Load()
Timer1.Enabled = True
Timer1.Interval = 1000 '//This will regulate the speed of events
Timer1.Tag = -1
End Sub
Private Sub Timer1_Timer()
Dim i As Integer
Timer1.Tag = Val(Timer1.Tag) + 1
If Timer1.Tag = "0" Then
Label1.Caption = "Program is loading"
Exit Sub
End If
i = Val(Timer1.Tag)
If i < 8 Then
Label1.Caption = Label1.Caption & "."
Else
Timer1.Enabled = False
MAINFORM.Show
Unload Me
End If
End Sub
Right i have managed to sort the forms out but the program is now saying "......" and not program is loading and then ...... ?!?!?!??!
Dont surpose anyone could help.
My code is below-
Private Sub Timer1_Timer()
Dim i As Integer
Timer1.Tag = Val(Timer1.Tag) + 1
If Timer1.Tag = "0" Then
Label2.Caption = "Program is loading"
Exit Sub
End If
i = Val(Timer1.Tag)
If i < 8 Then
Label2.Caption = Label2.Caption & "."
Else
frmMainmenu.Show
Unload Me
End If