ObjectsByName

Returns the identifiers of all objects based on the objects' user-assigned name.

Syntax

rhinosriptsyntax.ObjectsByName (name, select=False, include_lights=False)

rhinosript.selection.ObjectsByName (name, select=False, include_lights=False)

Parameters

name

Required.  String.  The name of an object or objects.

select

Optional.  Boolean.  Select the objects.  If omitted, the objects are not selected (False).

include_lights

Optional.  Boolean.  Include light objects.  If omitted, light objects are not returned (False).

Returns

List

A list of Guids identifying the objects if successful.

Example

import rhinoscriptsyntax as rs

name = rs.GetString("Name to select")

if name: rs.ObjectsByName(name,True)

Also See