Source language: Translate to:

Make InternetPost/Get/Download run async

Post your suggestions for future versions of NeoBook

Moderator: Neosoft Support

Make InternetPost/Get/Download run async

Postby Tony Kroos » Tue Sep 28, 2010 1:33 am

Please make Internet functions run independently of neobook actions, so we don't have to wait for operation to complete before proceeding to the next actions. If so, it is possible to create custom progressbars using [DownloadProgress] without plugins (i tried, but no luck). Now its just a numbers. Also you may want to add more [Progress] variables (for file copy/move etc.) and error handling if any. thanks.
Tony Kroos
 
Posts: 402
Joined: Thu Oct 15, 2009 3:43 pm

Postby smartmedia » Tue Sep 28, 2010 1:58 am

Hi..

I agree you with you, my proposal to Dave is to add a process manager witch will handle all those functions needed to wait response from Internet to run independently without freeze the application. I don't know if this can be made but is very needful.
User avatar
smartmedia
 
Posts: 889
Joined: Fri Apr 01, 2005 6:50 am
Location: Hellas

Postby Tony Kroos » Tue Sep 28, 2010 4:13 am

For future development, you may add this possibility for some other commands (just like option to keep executing next actions in moveobjectalongpath command), so neobook actions will execute in parallel threads, not step-by-step. Or at least implement such option only for subprocedures (there will be no "Return" command at the end of sub, the script which called the procedure will go on), so different subs may be called at the same time and run independently. Then neobook actions will be greatly more flexible.
Tony Kroos
 
Posts: 402
Joined: Thu Oct 15, 2009 3:43 pm

Postby Gaev » Tue Sep 28, 2010 5:49 am

Tony, smartmedia:
Make InternetPost/Get/Download run async
All three commands have an option parameter where you can specify Async ... from the Help file ...
Allow NeoBook to respond to other input during the download. Without this option, NeoBook will not be able to accept user input until the download is complete.
I haven't used it myself ... but if this option does not allow you to continue processing your script ... you might consider use of the TimerObject ... set options Wait for "Timer Start" and Stop Timer after one execution ... and in the TimerInterval section, you can invoke the Internet related commands ... that will free the rest of NeoBook to respond to any of your other scripts and/or user interactions

Also from the Help file ...
[DownloadProgress]

This variable contains a number (0-100) that represents the progress of the current HTTP Action. Long HTTP Actions can be aborted by changing the contents of this variable to “Cancel”. For example:

SetVar "[DownloadProgress]" "Cancel"
Again, you can have ... the same Timer (without the "Execute Once" option) ... or another one ... that uses the value in this variable to display a Progress Bar
User avatar
Gaev
 
Posts: 3734
Joined: Fri Apr 01, 2005 7:48 am
Location: Toronto, Canada

Postby Neosoft Support » Tue Sep 28, 2010 10:04 am

Interesting suggestions. I will print this topic and add it to our list of things to consider for the future.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5603
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Postby Tony Kroos » Tue Sep 28, 2010 11:47 am

All three commands have an option parameter where you can specify Async ... from the Help file ...

Async option just allows "User Input" to pub, but we talking about proceeding to the next actions. It is impossible until previous Internet-action is completed.

you might consider use of the TimerObject ... set options Wait for "Timer Start" and Stop Timer after one execution ... and in the TimerInterval section, you can invoke the Internet related commands ... that will free the rest of NeoBook to respond to any of your other scripts and/or user interactions


Of course, first of all I tried Timer - no luck, it works from time to time, but... anyway, next timer step will not completely execute until Internet-action is done. It seems, timer object doesnt run in pure parallel thread, just simulates it. If so, I think Timer object's workflow should be revised.
Tony Kroos
 
Posts: 402
Joined: Thu Oct 15, 2009 3:43 pm


Return to NeoBook Suggestions

Who is online

Users browsing this forum: No registered users and 1 guest