I need a wait command
-
Hello all, Is there a way in VB 6.0 to make the system wait for a bit. Like system.wait(1000) where it will wait 1000 ms or something? I suppose I could write a for loop for 1 to SomeBigNumber and every 1000 do what I want to do, but this seems like a silly way to do things. Let me know please if there is a wait command. Thanks!! Oh yeah one other quick question. When I run my VB program, the Focus doesn't automatically start on the command button, like I would like. I went to the form load area and wrote cmd_calc.SetFocus (hoping that this would set focus to my command button) It gives me an error sayign invalid procedure call or argument. How can I get the focus to start on my command button? Again thank you very much! NickOne
-
Hello all, Is there a way in VB 6.0 to make the system wait for a bit. Like system.wait(1000) where it will wait 1000 ms or something? I suppose I could write a for loop for 1 to SomeBigNumber and every 1000 do what I want to do, but this seems like a silly way to do things. Let me know please if there is a wait command. Thanks!! Oh yeah one other quick question. When I run my VB program, the Focus doesn't automatically start on the command button, like I would like. I went to the form load area and wrote cmd_calc.SetFocus (hoping that this would set focus to my command button) It gives me an error sayign invalid procedure call or argument. How can I get the focus to start on my command button? Again thank you very much! NickOne
NickOne wrote: Is there a way in VB 6.0 to make the system wait for a bit. Look in the SDK for the Sleep Win32 API call Look here for an example: http://www.buygold.net/v02n11/v02n11.html[^] NickOne wrote: It gives me an error sayign invalid procedure call or argument. How can I get the focus to start on my command button? Place the setfocus call in the formActivate event. The form load event fires as the form is being built and the control might not be available at that point yet. It will also help if you have all the controls Tab orders and indexes set properly.
Paul Watson wrote: "At the end of the day it is what you produce that counts, not how many doctorates you have on the wall."
George Carlin wrote: "Don't sweat the petty things, and don't pet the sweaty things."