The following builds on that alternative. It collects message-texts and displays that collection at a chosen point(s) in the script. In the mentioned Firefox example, the dialogue does disappear too in this way. However, the script's 'history track' is displayed as collected.
First the subroutine to be inserted in the code:
Code: Select all
//
// ****** Display collected debug message
// Collect message to be displayed by
// let>dbgMsg=%dbgMsg%%CRLF% string of message to be collected
// gosub>showDbgMsg display collected message and exit
// gosub>showDbgMsg,1 display collected message and return to caller
//
SRT>showDbgMsg
Let>MSG_STAYONTOP=1
Let>MSG_CENTERED=1
Let>MSG_XPOS=0
Let>MSG_YPOS=0
Let>MSG_HEIGHT=750
Let>MSG_WIDTH=1500
MessageModal>dbgMsg
if>showDbgMsg_var_1<>1
exit>0
endif>
// for next call to work with yes/no exit par
let>showDbgMsg_var_1=
END>showDbgMsg
Code: Select all
if>a=3
// your code i.e. pase1Result=OK
let>dbgMsg=%dbgMsg%%CRLF% message to add to the collection, like case a=%a%
else>
// your code i.e pase1Result=Error
let>dbgMsg=%dbgMsg%%CRLF% message to add to the collection
endif>
let>dbgMsg=%dbgMsg%%CRLF%Phase 2, starting
if>pase1Result<>OK
// your code
let>dbgMsg=%dbgMsg%%CRLF% Phase 2 started, Phase 1 results was %pase1Result%
endif>
Code: Select all
gosub>showDbgMsg
//or
gosub>showDbgMsg,1
// if control should return here after the message display