Jump to content

Recommended Posts

Posted

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

Posted

Actually what I've seen in a forum is Adlibenable but that function is not in the autoit so I thought Adlibregister also same.. If you don't could you pls tell me how to apply albiregister to this 

 

Posted

I checked but can you pls tell me to where I need to put my script in? Between the Albiregister function or myadlibregister function or top of these two function?

  • Moderators
Posted (edited)

@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!

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
  • Recently Browsing   0 members

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