LightName

Returns or modifies the user-definable name of a light object.

Syntax

rhinoscriptsyntax.LightName (object_id, name=None)

rhinoscript.light.LightName (object_id, name=None)

Parameters

object_id

Required.  String or Guid.  The identifier of the light object.

name

Optional.  String.  The new light name.  If omitted, the current light name is returned.

Returns

String

If name is not specified,  the current light name if successful.

String

If name is specified,  the previous light name if successful.

Example

import rhinoscriptsyntax as rs

id = rs.GetObject("Select a light", rs.filter.light)

if id:

    name = rs.GetString("New light name")

    if name: rs.LightName(id, name)

Also See

EnableLight

IsLight

IsLightEnabled

LightColor

LightCount

LightObjects