Script Limits
Richard Gaskin
ambassador at fourthworld.com
Thu Aug 7 12:52:01 EDT 2003
Mark Talluto wrote:
> In my case, I usually am updating code to controls with the set the
> script of.... There is no other way to use the same control with new
> code.
While I agree that the proposed change to script limits is likely more of a
problem in itself than a solution, there is at lease one other alternative
for your scenario.
Rather than writing self-modifying code you could set a property in the
object and handle the various behaviors in a backscript using a switch
block:
on MySpecialBehavior
switch the uBehaviorClass of the target
case "Something"
doSomnething
break
case "SomethingElse"
doSomethingElse
break
end switch
end MySpecialBehavior
The overhead of the switch block is a fraction of a millisecond and allows
you to centralize your code into a common library. This may simplify
debugging, and likely simplify maintenance as well should you ever need to
alter the behavior.
--
Richard Gaskin
Fourth World Media Corporation
Developer of WebMerge: Publish any database on any Web site
___________________________________________________________
Ambassador at FourthWorld.com http://www.FourthWorld.com
Tel: 323-225-3717 AIM: FourthWorldInc
More information about the metacard
mailing list