InformationModel.MakeObject(browseName, objectTypeId)
Creates a project object of the type passed in the second argument and returns a corresponding IUAObject C# object type.
static IUAObject MakeObject(QualifiedName browseName, NodeId objectTypeId);
Arguments
-
browseName(QualifiedName) - The
BrowseNameof the new object. objectTypeId(NodeId)- The
NodeIDof the type from which the new object is derived.
Returns
IUAObject- A C# object that corresponds to the project object created.
Example
The following example shows an API that creates a
NewMotor object derived from Motor (type), searched with the Find method, and then specified using NodeID:
var motorType = Project.Current.Find("Motor");
var mymotor = InformationModel.MakeObject("NewMotor", motorType.NodeId);
