Jump to content

Recurrence Script


Recommended Posts

Hi,

I'm new to auotoit. I need to run my script in every hour. So to write this first I've tried to run the script in every minute. After seeing few forum questions and answers I've came up with below and I wrote it in bottom of the script. But It didn't work. Pls give me a solution. Thanks in advance !

Func Adl();; Normal running scipt

While 1

$Interval = 60000 ;1000 ms = second

AdlibRegister('myadlib', $Interval * 01)

WEnd

EndFunc
Func myadlib();; Script running every hour


EndFunc

While 1
WEnd

Link to comment
Share on other sites

  • Developers
2 minutes ago, VinodS1997 said:

Pls give me a solution. Thanks in advance !

mmm... Did you open the helpfile and check for AdlibRegister() ?

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

...so did you open the helpfile this time before asking?  guess not as there is an example how to use it! ;) 

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Moderators

@VinodS1997 The help file has a very clear example of how to use adlibregister, did you follow that format? Looking at the code you posted above, it is never going to do anything, since your myadlib() function is empty. You need to actually put something inside the function; or if you are truly unsure how, explain in detail what you are trying to accomplish, and we will try to help. But no one can assist when you just post a couple lines of unusable code.

 

50 minutes ago, VinodS1997 said:

Func Adl();; Normal running scipt

While 1

$Interval = 60000 ;1000 ms = second

AdlibRegister('myadlib', $Interval * 01) ;<---calling the function

WEnd

EndFunc
Func myadlib();; Script running every hour

;<=========================>  <----------------function doesn't DO anything.
EndFunc

While 1

;<=========================> <----------------While loop doesn't DO anything.
WEnd

 

Edited by JLogan3o13

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...