Best Practices in Rev development

Stephen Barncard stephenREVOLUTION at barncard.com
Thu Jun 21 14:29:10 EDT 2007


yes, I know about BREAK. I was showing a unique use of NOT using break.
And why would one not want BREAK? It's a standard and useful term in 
SWITCH/CASE.

I would put a break like this if I didn't want the default to execute too.

SWITCH pKey
    CASE "B"
    CASE return
    CASE "P"
      printThePage
    BREAK
    default
      doDefaultThing
END SWITCH


>I agree, much cleaner and easier to follow and write, so long as you 
>don't forget to exit each of the case statements so as not to have 
>subsequent ones executed as well. I believe this is a feature in 
>Rev, though I'd prefer if it weren't.
>
>Joe Wilkins

-- 


stephen barncard
s a n  f r a n c i s c o
- - -  - - - - - - - - -






More information about the use-livecode mailing list