|
-
Oct 2nd, 2002, 05:04 PM
#1
Thread Starter
Addicted Member
timer... *SOLVED*
i have a timer but for some reasons, when the app loses focus, the timer doesn work is there a way to tell the timer to keep going even when the form is not in focus?
Last edited by Rudy; Oct 2nd, 2002 at 05:32 PM.
*Rudy^
Visual Studio 6 Ent. SP5
Windows 2000 SP4
Windows XP SP1a
-
Oct 2nd, 2002, 05:05 PM
#2
Thread Starter
Addicted Member
actually, the form is .visible = false
*Rudy^
Visual Studio 6 Ent. SP5
Windows 2000 SP4
Windows XP SP1a
-
Oct 2nd, 2002, 05:06 PM
#3
-
Oct 2nd, 2002, 05:09 PM
#4
Thread Starter
Addicted Member
100% sure
the timer is supposed to call another form after a while, but if i go and start doing stuff (ie: open IE or something else) the form wont appear but if i just sit there and wait, it will
*Rudy^
Visual Studio 6 Ent. SP5
Windows 2000 SP4
Windows XP SP1a
-
Oct 2nd, 2002, 05:15 PM
#5
-
Oct 2nd, 2002, 05:16 PM
#6
Need-a-life Member
This code works!
VB Code:
Option Explicit
Private Sub Form_Load()
Me.Visible = False
End Sub
Private Sub Timer1_Timer()
Debug.Print "Hello"
End Sub
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Oct 2nd, 2002, 05:17 PM
#7
Thread Starter
Addicted Member
nop, im not touching the timer at all, the timer loads when the form load and i never ever touch the timer
but what i dont understand is that if i sit there and do nothing it will work but if i openanother window, it wont work
*Rudy^
Visual Studio 6 Ent. SP5
Windows 2000 SP4
Windows XP SP1a
-
Oct 2nd, 2002, 05:23 PM
#8
-
Oct 2nd, 2002, 05:27 PM
#9
Thread Starter
Addicted Member
//this loads the form the timer is on
frmTimer.hrs = Left(Data, 2)
frmTimer.Min = Mid(Data, 3, 2)
frmTimer.sec = Mid(Data, 5, 2)
Load frmTimer
//this is what the timer does
Private Sub Timer1_Timer()
sec = sec - 1
If sec = 0 Then
If min = 0 Then
If hrs = 0 Then
Load frmMain
frmMain.Show
Unload frmTimer
End If
hrs = hrs - 1
min = 59
sec = 59
End If
min = min - 1
sec = 59
End If
End Sub
//this is the ONLY code contained in frmtimer
*Rudy^
Visual Studio 6 Ent. SP5
Windows 2000 SP4
Windows XP SP1a
-
Oct 2nd, 2002, 05:32 PM
#10
Thread Starter
Addicted Member
nevermind, i fixed my own problem, the form i was loading wasnt set properly....thanx anywayz
*Rudy^
Visual Studio 6 Ent. SP5
Windows 2000 SP4
Windows XP SP1a
-
Oct 2nd, 2002, 05:37 PM
#11
Need-a-life Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|