PDA

View Full Version : Stop subsequent scripts from running


laShan
02-13-2004, 09:33 AM
If I have several scripts assigned to, let's say, wipe, how can I make the first one halt the chain of events? I tried different return configurations without any apparent luck.

Harm
02-13-2004, 09:36 AM
If the first one returns non-zero, the others aren't called.

laShan
02-13-2004, 09:43 AM
That's just the thing, they are. Either I'm doing something really weird, or there's some sort of issue. Shouldn't the following stop the process?

iputs "Command aborted!"
return 1

Harm
02-13-2004, 09:56 AM
If you're using itcl, you could try that:

iputs "Error message"
global ioerror; set ioerror 1; return 1

laShan
02-13-2004, 09:59 AM
Thanks! That did the trick :)