ObjectTableReplace Method (ObjRef, RhinoObject) |
Replaces one object with another. Conceptually, this function is the same as calling
Setting new_object attributes = old_object attributes
DeleteObject(old_object);
AddObject(old_object);
Namespace:
Rhino.DocObjects.Tables
Assembly:
RhinoCommon (in RhinoCommon.dll)
Since: 5.0
Syntax public bool Replace(
ObjRef objref,
RhinoObject newObject
)
Public Function Replace (
objref As ObjRef,
newObject As RhinoObject
) As Boolean
Parameters
- objref
- Type: Rhino.DocObjectsObjRef
reference to old object to be replaced. The objref.Object() will be deleted. - newObject
- Type: Rhino.DocObjectsRhinoObject
new replacement object - must not be in document.
Return Value
Type:
Booleantrue if successful.
See Also