IDChanged | ||||||||||
Type | message | |||||||||
Dictionary | LCS | |||||||||
Library | LiveCode Script | |||||||||
Syntax |
| |||||||||
Associations | image | |||||||||
Summary | ||||||||||
Introduced | 1.0 | |||||||||
OS | mac, windows, linux, ios, android | |||||||||
Platforms | desktop, server, mobile | |||||||||
Parameters |
| |||||||||
Example |
| |||||||||
Related | Property: altID, ID Message: nameChanged Keyword: image, integer Object: stack, image Function: stacks Glossary: object, property, trap, message, image Control Structure: pass | |||||||||
Description | Handle the IDChanged message if you want to make updates when an image's ID is changed. The ID property of most objects is set when the object is created and cannot be changed. There are two exceptions:stacks and images. You can set the ID of an image to any positive integer. Be careful not to set an image ID to a number that's the ID of another image in the same stack : since LiveCode uses IDs to keep track of objects, a conflict may result in the inability to access one or both objects. The following ID numbers are reserved and should not be used for image IDs:
The actual change is not triggered by the IDChanged message, so trapping the message and not allowing it to pass does not prevent the ID from being changed. | |||||||||
Tags | objects |