ObjectDisplayMode

Returns the display mode of an objects. Object display modes are view based. Thus, it is possible to have an object display different in different views.

Syntax

Rhino.ObjectDisplayMode (strObject [, strView])

Parameters

strObject

Required.  String.  The identifier of the object to query.

strView

Optional.  String.  The title or identifier of the view.  If omitted, the current active view is used.

Returns

String

The identifier of the display mode if successful.

Null

If not successful, or on error.

Example

Dim strObject, strMode

strObject = Rhino.GetObject("Select object")

If Not IsNull(strObject) Then

  strMode = Rhino.ObjectDisplayMode(strObject)

  If IsNull(strMode) Then

    Rhino.Print "The object does not have a custom display mode."

  Else

    Rhino.Print "Display mode = " & Rhino.ViewDisplayModeName(strMode)

  End If

End If

Also See

AddObjectDisplayMode

RemoveObjectDisplayMode

ViewDisplayModeName

ViewDisplayModes