How to Pause for a random time?

nnCron and nnCron LITE discussion

How to Pause for a random time?

Postby Fantast.Leo.Dou » Wed, 31 Aug 2016, 11:07

For example, to pause a random time between 0 and 5000

Code: Select all
5000 RANDOM radom_var !
PAUSE: radom_var @


But nncron give me an error when execute this task.
Please tell me how? Thanks.
Fantast.Leo.Dou
 
Posts: 39
Joined: Wed, 23 Feb 2005, 07:29

Re: How to Pause for a random time?

Postby semko » Wed, 31 Aug 2016, 14:45

Did you declare the variable random_var?
Try it this way:

Code: Select all
#( test_random
VARIABLE random_var
WatchHotKey: "@{F5}"
Action:
5000 RANDOM random_var !
random_var @ PAUSE
MSG: "Random: %random_var @%"
)#
semko
 
Posts: 46
Joined: Sat, 08 Oct 2005, 17:42
Location: Germany

Re: How to Pause for a random time?

Postby Fantast.Leo.Dou » Thu, 01 Sep 2016, 03:38

Thank you very much.
It's problem of
Code: Select all
PAUSE: radom_var @
,
It must be
Code: Select all
random_var @ PAUSE
Fantast.Leo.Dou
 
Posts: 39
Joined: Wed, 23 Feb 2005, 07:29


Return to nnCron forum (English)

Who is online

Users browsing this forum: Bing [Bot] and 4 guests

cron