How to Reset ID's of Controls

Ender Nafi Elekcioglu endernafi at keehuna.com
Mon Jan 27 05:21:39 EST 2014


Since, there isn’t any native command to do this;
I created a new stack and copied my cards to it.

It resulted two things:
1. My background group has completely gone crazy.
Now the group itself is *shared* and *background*, but its controls are not.
Interesting, isn’t it?
I have a field “instructions” for example.
Its content is different on each card.
It has a couple of nested groups whose rects are different on each card.

2. After all, my struggle of hours was pointless.
Because the ids could reach to 5 figures {34657} in no time.
I was creating some controls on the fly and delete them on closeCard or closeStack;
and apparently Livecode doesn’t reset the ids at all.

It just adds up to the recent id regardless of that control deleted or not.

So, does that mean if the user runs the app, say 1000 times, the ids will reach zillion figures?
I have tens of cards, each one has hundreds of controls 
and I create those controls on each time the user navigates to those cards.


I’m confused, this is a crucial project, my client is a governmental institution
and I can’t afford if all users start to report crashes a couple of months later.


Or am I being paranoid here?

It’s an iOS project, btw.


Appreciate every insight,

Thanks…

~ Ender



More information about the use-livecode mailing list