customPropertySet | |||||||
Type | property | ||||||
Dictionary | LCS | ||||||
Library | LiveCode Script | ||||||
Syntax |
| ||||||
Associations | stack, field, button, graphic, scrollbar, player, image | ||||||
Summary | Specifies a set of custom properties applied to an object. | ||||||
Introduced | 1.0 | ||||||
OS | mac, windows, linux, ios, android | ||||||
Platforms | desktop, server, mobile | ||||||
Example |
| ||||||
Values |
| ||||||
Related | Command: set Property: customPropertySets | ||||||
Description | Use the customPropertySet property to create and switch between sets of custom properties and property values. An object can have multiple sets of custom properties. Each set is independent of the others, and the same property can have different values in different sets. To make a set's custom properties accessible, set the object's customPropertySet property to the name of the set you want to use. The values and properties in the current customPropertySet are used when you refer to a custom property. If the setName is not already a custom property set, setting the customPropertySet to the setName creates a custom property set named setName for the object. To use the default set of custom properties, set the customPropertySet to empty. You can access a property that is not part of the current customPropertySet using array notation. For example, the following statement gets the value of a custom property named "foo" in a custom property set named "myCustomSet" :
If using arbitrary custom property names, be aware that it won't be possible to access them by changing the customPropertySet if they clash with LiveCode language keywords. Instead, either use the array style notation above, or use a prefix to prevent name clashes (for example "uName" instead of "name" ). | ||||||
Tags | properties |