-
Nov 1st, 2013, 03:09 AM
#1
Thread Starter
New Member
loop action
I have a project that executes something at form_load, then 60 seconds later the project closes itself with the "unload me" command in timer section.
I want to make a variation where upon form load, it repeats the action every 10 minutes non-stop until I terminate the executable.
I want something like this:
- open the form
- loop the next two actions indefinetely
- run the task
- count 15 minutes
-
Nov 1st, 2013, 04:35 AM
#2
Re: loop action
Thread moved from the 'CodeBank VB6' forum (which is for you to post working code examples, not questions) to the 'VB6 and earlier' forum
-
Nov 1st, 2013, 04:47 AM
#3
Re: loop action
What actions do you to preform in the loops and what task do you want to run? Also, should it be 10 minutes not 15 minutes?
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
Nov 1st, 2013, 08:52 AM
#4
Re: loop action
So place the code you want to repeat in a sub routine
Call the sub routine from form load
Use a timer to call the sub routine in the tick event when the time is up
You will need a counter var to keep track of how many times the timer fires so you can get the timing right as a timer does not go that high or you can use the clock to check in the timer event to see if the desired amount of time has passed then call the sub routine
Tags for this Thread
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
|