Jump to content

pause in Visual basic 2008

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
2 replies to this topic

#1
igee

igee

    Newbie

  • Members
  • Pip
  • 1 posts
Please help me on making a simple PAUSE program in VB 2008(9.0)... We are making a thesis as for now. We needed a pause program on our program in visual basic 2008 but i don't know how.PLeasseee help me....u are a big help.thanks and God bless..

#2
Ray Tawil

Ray Tawil

    Programmer

  • Members
  • PipPipPipPip
  • 108 posts
what do you mean by pause?

if you mean delay during program execution then this might help:

Sub Delay(dblSecs As Double)
Const OneSec As Double = 1# / (1440# * 60#)
Dim dblWaitTil As Date

dblWaitTil = Now + OneSec * dblSecs
Do Until Now > dblWaitTil
DoEvents ' Allow windows messages to be processed
Loop

End Sub


#3
Ray Tawil

Ray Tawil

    Programmer

  • Members
  • PipPipPipPip
  • 108 posts
you can also do it this way

Quote

msgbox("i am stoping")
Sleep 5000
msgbox("i am back")