Sub-Assembly in Tekla

Hello everyone. I’m working with a precast and I want to create some components, but the last part of this work I don’t understand.
How can I add steel part as sub-assembly to the concrete element (cast unit)?


In Input can be cast unit and steel part or assembly.

Thank you

How I understand it isn’t possible without C# and just with Tekla live link

Hi Yahor, sorry for the late answer.

Indeed there are no components for adding parts to an existing cast unit. Unless you already did so, you can create a C# component that does this. E.g. something like this:

var assembly = AssemblyIn as Tekla.Structures.Model.Assembly;
var objToAdd = ObjectIn as Tekla.Structures.Model.ModelObject;

if (objToAdd is Tekla.Structures.Model.IAssemblable)
{
  var sub = (objToAdd as Tekla.Structures.Model.IAssemblable).GetAssembly();
  assembly.Add(sub);
}

assembly.Modify();
new Tekla.Structures.Model.Model().CommitChanges();

AssemblyIn and ObjectIn would be your inputs. Remember to add assembly references for the C# component to Tekla.Structures.dll and Tekla.Structures.Model.dll in the install folder of the Tekla version you’re using.

Cheers,

-b

1 Like

Super. Thank you for your answer. I will try to do it. The next step of learning it will be C#, so that later such issues can be solved independently :slight_smile:

1 Like

:ok_hand: Sounds good, here are some more detailed instructions about setting up a C# scripting component if needed: Grasshopper-Tekla Live Link FAQ | Tekla User Assistance

1 Like