TeraTerm Macroscript: Countdown timer

617 Views Asked by At

Is it possible to write a macroscript that displays a countdown timer?

I am trying to include a timer in my macroscript that runs in teraterm but i tried timeout it does not do any display.

Greatly appreciate the help! Thank you!

1

There are 1 best solutions below

0
On
timerStartValue = 10;
timeRes = 1
call RunTimer
end

:RunTimer
    timerCurrVal = timerStartValue
    while (timerCurrVal >= 0)
        sprintf2 output "%d" timerCurrVal
        statusbox output 'Timer'
        timerCurrVal = timerCurrVal - 1
        pause timeRes
    endwhile
return

This timer is blocking. You should elaborate more on how and where you want to use this timer.