Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

GetTickCount question?

Status
Not open for further replies.

Sidro

MIS
Sep 28, 2002
197
US
Hi,
Im making a text scroller using this function, GetTickCount from the windows "Kernel32" DLL file.
The text scroller loooks like a type writer affect; printing each charactor and delay a 3 second before printing another charactor. The problem im having is breaking out.When the GetTickCount is in affect, It takes priority over my apps. I cant break out at all. I would have to wait until it finishes before executing another command. I cant have control over it. Is there a better way to do a delay that I can break out if I wanted to.
Thanks.
 
The Timer control is probably the easiest way of doing this. Just put a Timer control on the form with Enabled = True and Interval set to 3000 ( = 3 secs)

Then do your stuff in the Timer event:

Private Sub Timer1_Timer()
Text1.text = .... ' whatever you want here
End Sub

This routine runs every 3 secs until you set Timer enabled to False


________________________________________________________________
If you want to get the best response to a question, please check out FAQ222-2244 first

'People who live in windowed environments shouldn't cast pointers.'
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top