Duplicate Object IDs with Sub Stack
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Duplicate Object IDs with Sub Stack
Hi all,
Hope you all can help. I have a main stack and a sub stack which stores 95% of my images.
However I have run into a problem as some of the objects I have added in the main stack have the same IDs as the the sub stack and this is causing problems.
Is there fast/automated way to check if there is any conflicts/duplicate IDs across both stacks? or a fix for this problem?
thanks
Hope you all can help. I have a main stack and a sub stack which stores 95% of my images.
However I have run into a problem as some of the objects I have added in the main stack have the same IDs as the the sub stack and this is causing problems.
Is there fast/automated way to check if there is any conflicts/duplicate IDs across both stacks? or a fix for this problem?
thanks
Re: Duplicate Object IDs with Sub Stack
HI istech,
what problems are you experiencing?
Duplicate IDs in different stack is normal behavior!
You could script a solution to check the IDs, but maybe this is not neccessary.
But therefore we need to know the problem!
Remember that you can change objects IDs if you really want to, at your own risk of course
But that makes sense when it comes to IMAGE ID conflicts!
Best
Klaus
what problems are you experiencing?
Duplicate IDs in different stack is normal behavior!
You could script a solution to check the IDs, but maybe this is not neccessary.
But therefore we need to know the problem!
Remember that you can change objects IDs if you really want to, at your own risk of course

But that makes sense when it comes to IMAGE ID conflicts!
Best
Klaus
Re: Duplicate Object IDs with Sub Stack
I suggest to not use ID's in all places where you have a choice. I think the only places where you have to use id's are icons and behaviors.
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
Re: Duplicate Object IDs with Sub Stack
Hi,
The problem I have run into is when I import images from a folder into the sub stack and use them as icons in buttons etc in the main stack.
Some of the objects share ids on the main stack so when I reference a image(using a id) from the sub stack I get a main stack image(etc) from time to time.
As I continue moving through the project creating new buttons or players etc this issue can cause problems. Is there a solution for this?
I hope this makes sense.
ps. and yes Klaus I have had to change quite a few...of the ones I found
The problem I have run into is when I import images from a folder into the sub stack and use them as icons in buttons etc in the main stack.
Some of the objects share ids on the main stack so when I reference a image(using a id) from the sub stack I get a main stack image(etc) from time to time.
As I continue moving through the project creating new buttons or players etc this issue can cause problems. Is there a solution for this?
I hope this makes sense.

ps. and yes Klaus I have had to change quite a few...of the ones I found

-
- VIP Livecode Opensource Backer
- Posts: 10052
- Joined: Sat Apr 08, 2006 7:05 am
- Contact:
Re: Duplicate Object IDs with Sub Stack
IDs are settable. Tedious, but you could change the ID values from the ones they were imported with to make them unique across your project.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: Duplicate Object IDs with Sub Stack
Thanks Richard,
Yes this has been the case. Just checking to see if there was any other faster method.
I suppose it would be nice to see all the IDs in the application browser under a separate column. I could then do a sort and see if there are any duplicates among the stacks.
In any case thanks for your replies.
Yes this has been the case. Just checking to see if there was any other faster method.
I suppose it would be nice to see all the IDs in the application browser under a separate column. I could then do a sort and see if there are any duplicates among the stacks.
In any case thanks for your replies.
Re: Duplicate Object IDs with Sub Stack
Ah i see, an image library substack. One way that I made work before is to set the id of the substack to a high value, for example I tend to use 300000. That way, all id's of new objects will start from there, which reduces the likeliness of conflicts.
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
Re: Duplicate Object IDs with Sub Stack
Yes in fact I started to do this and made it 500 away from my main stack IDs.
In the end it was no way enough looks like IDs 30k and above is the option.
In the end it was no way enough looks like IDs 30k and above is the option.
