Tinderbox v9 Icon

type("attributeName")


Operator Type: 

Operator Scope of Action: 

Operator Purpose: 

Operator First Added: 

Operator Altered: 

 Function   [other Function type actions]

 Document   [operators of similar scope]

 Document configuration   [other Document configuration operators]

 9.0.0

 


type("attributeName")

This operator may be replaced by the more flexible attribute() operator.

The operator type(attributeName) returns a string representing the type of the designated attribute. The attribute may simply be the attribute name (without quotes or a preceding "$") or an expression that, when evaluated, yields an attribute name.

$MyString = type(Width); → "number"

$MyString = type("AccentColor"); → "color"

$MyString="Modified"; type($MyString); → "date"

Note that type($MyString) returns the type of the attribute who name is stored in $MyString, while type("MyString") or type(MyString) returns the type of the attribute MyString.

If no such attribute exists in the document, the operator returns the empty string.