Skip to main content

objectRemove

objectRemove ( object : object , property : string )

ParameterTypeDescription
objectobject->Object to edit
propertystring->Name of property to remove

Description

The objectRemove command removes property from the object.

The command removes the property as well as its current value.

In the property parameter, pass the label of the property to be removed. Note that the property parameter is case sensitive.

If the property is not found at the first level of object, the command does nothing.

Example

 var obj : object

obj = {name : "Smith", info: {a: 20, b: 30}}
objectRemove(obj, "name")
//obj: {"info": {"a": 20, "b": 30}}
objectRemove(obj.info, "b")
//obj: {"info": {"a": 20}}