--- In [email protected], Alan Martin <[EMAIL PROTECTED]> wrote:
>
> This is all happening in a script called by another script which
> expects a result.
> If we quit early because the condition is not true
> then I want to return an alternative result, called "different" below.
>
> I guess I could change all my scripts from my current method
> [which shows an error "missing endif" in 4.5.03a, when condition == 0]
>
> ;; my current method 1
> if(not condition)do
> debug Not true so we quit
> quit("different")
> endif
> debug True so we continue
> result = "something"
> quit(result)
You may avoid using if()do-endif in this case, as win.debug() returns
nothing:
if(not condition)
quit(win.debug("Not true so we quit")++"different")
debug True so we continue
result = "something"
quit(result)
Sean
------------------------ Yahoo! Groups Sponsor --------------------~-->
Great things are happening at Yahoo! Groups. See the new email design.
http://us.click.yahoo.com/TISQkA/hOaOAA/yQLSAA/JV_rlB/TM
--------------------------------------------------------------------~->
Attention: PowerPro's Web site has moved: http://www.ppro.org
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/power-pro/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/