AdlibEnable: Difference between revisions

From AutoIt Wiki
Jump to navigation Jump to search
(New page: Adlib's functionality is like that of combining Sleep with Call in that a function will be called after so many milliseconds. =Syntax= AdlibEnable("''func''"[, ''time'']) =Param...)
 
m (BrokenLinks(FunctionList): ...)
Line 1: Line 1:
Adlib's functionality is like that of combining [[Sleep]] with [[Call]] in that a function will be called after so many milliseconds.
Adlib's functionality is like that of combining {{Help File|Sleep}} with {{Help File|Call}} in that a function will be called after so many milliseconds.


=Syntax=
=Syntax=
Line 28: Line 28:


=Related Functions=
=Related Functions=
[[AdlibDisable]] [[Call]] [[Sleep]]
<nowiki>[[AdlibDisable]] [[Call]] [[Sleep]]</nowiki>

Revision as of 14:01, 17 November 2012

Adlib's functionality is like that of combining Sleep with Call in that a function will be called after so many milliseconds.

Syntax

AdlibEnable("func"[, time])

Parameters

funcName of function to be called.
timeTime in milliseconds till next func call. Default 250ms. (Optional)

Return Value

None.

Example

Local $x = 0, $y

Func myFunction()
  $y = MsgBox(1,"Count the boxes",$x,1)  ; timeout in 1 second
  if $y = 2 then Exit  ; exit on cancel
  $x += 1
  AdlibEnable(myFunction(),1000)  ; call this function again in 1 second
EndFunc

myFunction()

Related Functions

[[AdlibDisable]] [[Call]] [[Sleep]]