Showing results for 
Search instead for 
Do you mean 
Reply
Solved! Go to solution

[C# 11.1] How to create an equipment prototype and add components to it

Hello,

how can I programmatically create an equipment prototype, set it in modelling scope and add some components to it?

 

The first two lines of the following code do load the components to the same level as the EP. The third line throws an TxNotImplementedException.

TxInsertComponentCreationData data = new TxInsertComponentCreationData(subcomponent.InstanceName, path);
ITxComponent comp = root.InsertComponent(data); 
ep.AddObject(comp); // ep is of type TxComponent and represents the  Equipment Prototype.

Is there another way to do this?

1 REPLY
Solution
Solution
Accepted by topic author MarkusH
‎04-14-2016 07:15 AM

Betreff: [C# 11.1] How to create an equipment prototype and add components to it

Ok, I found the answer in V12.1.3 SDK Help file:

 

The following items are new in version 12.1.1:

Modeling

   The ability to set a selected component as modeling scope was added to ITxComponent .
   The ability to end modeling and store a modeled object was added to ITxComponent .
   The ability to create equipment was added to TxPhysicalRoot and TxComponent .

Kinematics API

   The new ITxKinematicsModellable interface was introduced, with the ability to:
   Create link, using CreateLink .
   Create joint, using CreateJoint .
   Couple joints, using CoupleJoints .