ID's are settable???
ambassador at fourthworld.com
Thu Jan 13 11:46:57 CST 2011
David Bovill wrote:
> Richard - what happens in your test if you reset the ids of objects - can
> you reset the stack ID and hence that of all newly created objects by some
> combination of setting all the obects say back to their fressh id status?
> That is is the stack id not automatically created as the incremental
> increase of the biggest real id - and not stored as a prop? If so it should
> work to reset the ids back to 1002++ with or without resetting the stack id?
Apparently you can set the ID of a stack to a higher number than it
currently is, but attempting to set it to a lower number will generate
an error stating "invalid id (must be greater than current id)".
This is reasonable to expect given the stack's unique role as the
arbiter of IDs: as long as there's no internal list of all IDs
currently in use (and given the compact size of stack files I certainly
don't mind that there isn't), if you could set the stack ID lower you
would risk creating a new object whose ID would conflict with an
LiveCode training and consulting: http://www.fourthworld.com
Webzine for LiveCode developers: http://www.LiveCodeJournal.com
LiveCode Journal blog: http://LiveCodejournal.com/blog.irv
More information about the use-livecode