hello
i am having trouble with a program i am writing
it is to remind me to let my dog in when i let her out because i forget to let her in some times and she gets mad
anyway the program crashes when i hit the comand button
i think the problem is with the do until loop
i have been using VB for a while but i have avoided the do until and the do while loops because i know they are good at crashing computers
my code looks like this
Dim vartime1, vertime2, vertime3
Private Sub Command1_Click()
'get currant time in seconds after midnight
vartime1 = Val(Timer)
'set time for timer to stop...
'for this application it is a set time of 10 min
'or 600 seconds
vartime2 = Val(vertime1) + 600
'make sure program will work over midnight
If vertime2 > 86400 Then
vertime3 = Val(vertime2) - 86400
Else
vertime3 = Val(vertime2)
End If
'make form1 invisible so it is not in the way
'timer will be running the the background
Form1.Visible = False
'us a do until loop till vertime3 = timer
Do Until Val(vertime3) = Val(Timer)
Loop
'make form2 visible
Form2.Visible = True
End Sub
if i just used bad syntax (not that i ever do

) and someone knows how to fix it that would be cool
but if it is just a imposible idea and it is not fixable and it cant be done that way i would like to know how it can be done
thanks in advance for all your help