Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #30218
    Patrick C
    Participant

    Is there a way to show status / progress updates when “Redraw = false;”?

    Example:

    #language = "V8"
    #async = "off"
    
    "use strict";
    
    status = "";
    
    Redraw = false;
    
    status = "Processing part 1";
    Sleep(1000);
    status = "Processing part 2";
    Sleep(1000);
    status = "Processing part 3";
    
    Redraw = true;

    In the example, “Processing part 1” and “Processing part 2” will never be shown.

    The progress updates don’t necessarily have to appear in the status bar.

    #30219
    Yutaka Emura
    Keymaster

    The status bar won’t be refreshed if Redraw is set to false, which is how the Redraw property is designed to function. If you need to display the status bar, temporarily change Redraw to true, and then switch it back to false when you’re done.

    #30220
    Patrick C
    Participant

    Thanks!

    In hindsight this question of mine wasn’t properly thought through.
    Normally I would have used the output bar (OutputBar) for status updates, but my code already used it for messages other than status updates.
    What I’m now doing is store the text for the output bar in a variable, which allows me to show status updates in the output bar.
    Once done the OutputBar is cleared and the output text written to the output bar.

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.