* /goto: 'label' not found - 10/08/03 06:38 AM
When you use /goto label and :label isn't found, you'll get this error.
I know this isn't a bug, however, I would like to suggest that it /returns at that point rather than raising an error and halting. If this is not possible, I would like to suggest a silent .goto that acts in this manner.
The reason this is an issue, is many people use labels as a fast and effecient Case Select instead of using many If-ElseIf-Else statements. The only problem is, if the Case doesn't exist, the script errors and halts.
Example of actual use I've seen:This code will error on all mouse and other events unless a :label is created for each of them.
In more extreme cases, I see goto $did with number labels of each dialog object, but unfortunately they have to include objects that don't apply just to keep it from erroring.
- Raccoon
I know this isn't a bug, however, I would like to suggest that it /returns at that point rather than raising an error and halting. If this is not possible, I would like to suggest a silent .goto that acts in this manner.
The reason this is an issue, is many people use labels as a fast and effecient Case Select instead of using many If-ElseIf-Else statements. The only problem is, if the Case doesn't exist, the script errors and halts.
Example of actual use I've seen:
Code:
goto $devent :sclick | do stuff | return :dclick | do stuff | return :edit | do stuff | return
In more extreme cases, I see goto $did with number labels of each dialog object, but unfortunately they have to include objects that don't apply just to keep it from erroring.
- Raccoon