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)?
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.