Hi Hans,

Even though GOTO and GOSUB are supported by KiXtart, in my opinion it would be better to craft your code so as to avoid the usage of those commands.

Something like this would only run when it was called and should end properly.


Code:
Dim $TestMsg

$TestMsg=DisplayMsg('This is a test of the message box from KiXtart')
If $TestMsg=1
? 'User selected OK'
Else
? 'User selected CANCEL'
EndIf

Function DisplayMsg($Message)
Dim $Msg,$MsgErr
$Msg=MessageBox($Message, 'Testing', 65)
$MsgErr=@ERROR
$DisplayMsg=$MsgErr
EndFunction



Edited by NTDOC (2004-11-22 09:51 PM)