|
Post by Julio on Jun 20, 2020 14:15:06 GMT
1 | RUN ACTION | DEFINE INTEGER VARIABLE | %INTEGER%::0
2 | RUN ACTION | INPUT BOX | Enter a integer number::::INTEGER
3 | RUN ACTION | GOTO MACRO LINE | Cont
* | Cont
4 | RUN ACTION | MESSAGE PROMPT | You have entered the number %INTEGER%::Resultado::0
This simple macro works correctly when it is written the first time. But after saved, if the macro list is cleaned
and the macro is reloaded from the folder, the label "* | Cont" is no longer found by "GOTO MACRO LINE | Cont".
To get it working I have to re-create the "* | Cont" tag every time I load the macro. On the other hand "RUN ACTION | INPUT BOX" shows the variable "INTEGER" instead of %INTEGER%
You have a good day
|
|
|
Post by Steve on Jun 21, 2020 6:27:17 GMT
Hi Julio, Thanks for pointing this out. GOTO again. wow. I've had a heap of issues with GOTO over the years. It seems like a simple function to get right but the dynamic shifting of the macro list during macro execution, as it turns out, has been difficult to nail down. I've marked this as bug MMM_BZ15 ( www.turnssoft.com/bugtrack.html#bugs). I found the issue in the code. If your interested the issue was that when a macro is read back in to the macro list from a saved .mmmacro file it was not removing the trailing LF (new line) at the start of the line. So instead of this: * | Cont
It was reading it in as: LF & * | ContWith the LF at the start I was never reading it in as a remark with a label.
Cheers and thanks again
|
|