Deutsches LiveCode Wiki
Advertisement

Specifies an alternate ID for objects.

Syntax:

set the altID of <object> to <IDNumber>

Examples:

put the altID of this card into myID
repeat while the altID of stack myStack <> 0

Use the altID property to specify an additional ID for an object. Both the ID and the altID property are checked when you refer to an object by ID.

This property can be used to ensure compatibility with imported SuperCard and HyperCard stacks that assume buttons and fields are created with sequential IDs. You can also use the altID of a stack as a consistent way of referring to it, since the ID of a stack changes every time an object is created.

Be careful not to set an object's altID property to the ID of an object of the same type. Since both properties are checked when you refer to an object by ID, doing this may cause the wrong object to be found because its altID property is the same as the ID of the object you want.

See also: stack (object), properties (property), ID (property), windowID (property)

Advertisement