Sorry about the previous post, I was changing the structure in my code, and was ‘distracted.’
Attached is a good sample of the code for a Web Dialog progress bar with a cancel button.
Hence, it will add time to a long loop if you update the progress bar too often.
It uses threads for SU8 & SU2013, and fibers for SU2014 +. Interestingly, if I force it to use Threads for 2014+, it BugSplats SU.
Just run/load from the Ruby console…
To use in your own code, your ‘long operation’ code needs to be passed in the setLoadProc_Cancel call.
ProgressBar.rb (8.7 KB)