## Property

Object Hierarchy | Related C++ Class: Property

### Inheritance

###

SIObject

ProjectItem

Property

### Description

The Property object represents a property of a SceneItem. For example, Softimage objects which have Properties include X3DObject, Model, Null, XSIProject, Group, Scene and Cluster.
Note: It is important to distinguish between the Softimage Property, which is a specific type of object, and the properties that are part of a scripting object's API (along with its methods). Similarily it is important to distinguish this object from Softimage Parameter objects, which are usually individual numeric attributes of an object. One visual way to think of the difference is to realise that a Property is represented by a Property Page and its Parameters are the individual sliders on that page.
Some properties, for example Visibility and Geometry Approximation, do not have specific objects in the Object Model and are represented with this Property object. Other Properties have their own specialized objects which inherit from Property, for example Material, ClusterProperty, UserDataMap, CustomProperty and StaticKinematicState.
A Property object may be local or shared. The SceneItem.LocalProperties property is convenient for finding just the local Properties on the parent object. The MakeLocal command can be used to make a local copy of a shared Property. The ProjectItem.Owners property can be used to find all owners of a shared Property. Because a shared property has multiple parents, the SIObject.Parent property can return different objects, depending on the context.
Often, the state of a Property object is exposed as Parameter objects. Other state is exposed as specific properties on the object, for example ClusterProperty.Elements and Material.CurrentImageClip.

### Methods

AddCustomOp | AddICEAttribute | AddScriptedOp | AddScriptedOpFromFile
AnimatedParameters2 | BelongsTo | EvaluateAt | GetICEAttributeFromName
IsA | IsAnimated2 | IsClassOf | IsEqualTo
IsKindOf | IsLocked | IsSelected | LockOwners
RemoveICEAttribute | SetAsSelected | SetCapabilityFlag | SetLock
TaggedParameters | UnSetLock |  |

### Properties

Application | Branch | BranchFlag | Capabilities
Categories | EvaluationID | Families | FullName
Help | HierarchicalEvaluationID | ICEAttributes | LockLevel
LockMasters | LockType | Model | Name
NestedObjects | ObjectID | Origin | OriginPath
Owners | PPGLayout | Parameters | Parent
Parent3DObject | Selected | Singleton | Type

### Examples

#### 1. VBScript Example

    'VBScript Example demonstrating the creation of a custom property

    newscene ,false

    set nullObj = Application.ActiveProject.ActiveScene.Root.AddNull

    set customProp = nullObj.AddProperty("Custom_parameter_list",, "MyCustomParam")

    'You can also access this property by name

    set customProp = nullObj.Properties.Item("MyCustomParam")

    'Custom Properties allow you to create your own paramters

    customProp.AddParameter "DoubleCustomParam", siDouble, , siReadOnly, _

    								, , , 0.695, 0.0123, 10.456

    LogMessage "Custom Property Name: " & customProp.Name

    LogMessage "Custom Property Fullname: " & customProp.FullName

    LogMessage "Custom Property Type: " & customProp.Type

    'Output of this script:

    'INFO : "Custom Property Name: MyCustomParam"

    'INFO : "Custom Property Fullname: null.MyCustomParam"

    'INFO : "Custom Property Type: customparamset"

#### 2. VBScript Example

    'vbscript: Example of Shared and Local Properties in Softimage

    newscene , false

    'Create a cylinder.  By default it will have several

    'local and inherited properties

    set oCyl = ActiveSceneRoot.AddGeometry( "Cylinder", "NurbsSurface" )

    PrintPropertyList oCyl.LocalProperties, "LocalProperties of Cylinder"

    PrintPropertyList oCyl.Properties, "Properties of Cylinder"

    'We can access properties by name

    set oKine = oCyl.Properties( "Kinematics" )

    set oMaterial = oCyl.Properties( "Scene_Material" )

    'However code like the previous line that assumes what the name

    'of the material will be not ideal, because the material could

    'be renamed as follows:

    oMaterial.Name = "MyMaterial"

    'So this is a safer way to access the material property

    set oMaterial = oCyl.Material

    logmessage "New material Name: " & oMaterial.Name

    'Material is an example of a Shared Property

    PrintPropertyList oMaterial.Owners, "Owners of Material "

    'Because we accessed the shared object via the Cylinder it will

    'say that the cylinder is the parent

    logmessage "Parent of Material: " & oMaterial.Parent

    'This is still the same Material

    logmessage "Another parent of same material: " & _

    			 ActiveSceneRoot.Material.Parent

    'This will give the cylinder its own copy of the material

    MakeLocal oCyl.Material

    logmessage "Number of owners after calling MakeLocal: " & _

    			 oCyl.Material.Owners.Count

    'Little helper routine to print out a collection

    sub PrintPropertyList( in_PropCollection, in_strHeading )

    	logmessage in_strHeading & " : "

    	dim	 oProp

    	for each oProp in in_PropCollection

    		logmessage "        " & oProp.Name

    	next

    end sub

### See Also

SceneItem.AddProperty SceneItem.Properties SceneItem.LocalProperties Scene.Properties XSIProject.Properties