Page 1 of 1

a few features I'm having trouble implementing

Posted: Thu Feb 23, 2017 6:24 pm
by nish81
Hi,

I'm looking for an alternative to the $5 barebones auto mouse clicker software I use right now, and I'm testing out Robotask. There are a few things that my current program has which I'm having trouble figuring out how to do on Robotask, and I was wondering whether I'm missing something:

1) The program I use right now shows an icon in the tray that's visible while there is at least one script running. So if I want to know whether a task is running I can just look to the tray quickly. Is there anything similar I can do here? I failed to find a workaround.

2) I'm also missing the ability to stop all tasks with a hotkey. The closest I can do is create a task that exits Robotask if I trigger it but then I have to deal with opening Robotask again etc. Is there anything closer to an 'abort all tasks' hotkey I can implement?

3) Finally, is it possible to randomise anything? For example I want to repeat the left click of my mouse every 2-2.5 seconds. I can set up the loop, but can only specify a fixed number of seconds, can't say 'some random time interval between 2000-2500ms'. Is that possible?

Thanks very much for any help!

Re: a few features I'm having trouble implementing

Posted: Fri Feb 24, 2017 11:40 am
by Oleg
1. RoboTask application has tray icon. If it in idle mode it looks like this
icon1.png
icon1.png (681 Bytes) Viewed 19118 times
The icon has red border if some task is running:
icon2.png
icon2.png (625 Bytes) Viewed 19118 times
2. Look at this task (see below)
The task contains small VB script which stops all running tasks.
Save the text of the task to a file and use menu Task->Import to import the task into RoboTask.
You can attach Hot-key trigger to the task

Code: Select all

;*****************************
;* RoboTask Task file
;* Do not edit in text editor!
;*****************************
 
[Root]
ActionAfterRun=INTEGER|0
Actions=FOLDER
Automat=INTEGER|-1
CatID=INTEGER|1040932817
Comment=STRINGLIST
ContinueOnError=INTEGER|0
ExternalName=STRING|"Task234"
Hide=INTEGER|0
ID=INTEGER|-9417660
LogOnAsUser=INTEGER|1
Name=STRING|"Stop all tasks"
OnErrorTaskID=INTEGER|-1
Priority=INTEGER|3
RunOnClose=INTEGER|0
RunOnStartup=INTEGER|0
ToLog=INTEGER|3
UnicodeFormat=INTEGER|1
WriteGeneralLog=INTEGER|0

[Actions]
Action1=FOLDER

[Actions\Action1]
ActionID=STRING|"A_SCRIPT_VBSCRIPT"
Enabled=INTEGER|-1
Name=STRING|"VB Script"
Params=FOLDER

[Actions\Action1\Params]
expandvars=STRING|"0"
line00000000=STRING|"for i=0 to RoboTaskApp.taskcount - 1 step 1"
line00000001=STRING|"  state = RoboTaskApp.taskinfostate(i)"
line00000002=STRING|"  if state = 3 then 'running"
line00000003=STRING|"    TaskName = RoboTaskApp.TaskInfoName(i)"
line00000004=STRING|"    extName = RoboTaskApp.TaskInfoExtName(i)"
line00000005=STRING|"    logmessage(""Stop task """""" + TaskName +"""""""")"
line00000006=STRING|"    RoboTaskApp.StopTask(ExtName)"
line00000007=STRING|"  end if"
line00000008=STRING|"next"
line0000000A=STRING|"LogMessage(""processed "" + cstr(i) + "" tasks"")"
linecount=STRING|"11"
savescript=STRING|"0"


3. Look at RandomValue variable. It can generate some random value
menu Options->Variables and select the Other group

Re: a few features I'm having trouble implementing

Posted: Mon Feb 27, 2017 8:56 pm
by nish81
Hi, thank you for the replies, I missed all these but the solutions work very well!

One question - for the icon the difference isnt very noticeable for me. If I can design my own icon (for use when a task is running) is it possible to replace the existing one somewhere in the program's files?

Re: a few features I'm having trouble implementing

Posted: Tue Feb 28, 2017 9:53 am
by Oleg
...is it possible to replace the existing one somewhere in the program's files?
Unfortunately no.

Re: a few features I'm having trouble implementing

Posted: Tue Feb 28, 2017 6:36 pm
by nish81
Okay, thank you for the replies!

Re: a few features I'm having trouble implementing

Posted: Thu Apr 27, 2017 8:09 pm
by robotask
To the OP, do you have Visual Basic, any edition?

if yes, you could simply create a short custom app, assign it a custom systray icon and launch it from Robotask. It would remain active and running as long as your Robotask task is active (you can iterate windows API tasks or keep a small .dat or .flag file in a temp folder). When your task stops, the VB app would also stop (as task is deleted or the .dat or .flag is deleted).