public static dynamic GetTSObject(CastUnitDrawing dynObject) { if (dynObject is null) { return(null); } return(dynObject.teklaObject); }
private string getObjectName(CastUnitDrawing currentDrawing) { var currentModelObject = _myModel.SelectModelObject(currentDrawing.CastUnitIdentifier); TSM.Assembly currentAssembly = currentModelObject as TSM.Assembly; TSM.Part currentMainPart = currentAssembly.GetMainPart() as TSM.Part; return currentMainPart.Name; }
private string getObjectName(CastUnitDrawing currentDrawing) { var currentModelObject = _myModel.SelectModelObject(currentDrawing.CastUnitIdentifier); TSM.Assembly currentAssembly = currentModelObject as TSM.Assembly; TSM.Part currentMainPart = currentAssembly.GetMainPart() as TSM.Part; return(currentMainPart.Name); }
private void changeDrawingName(CastUnitDrawing currentDrawing, string objectName) { currentDrawing.Name = objectName; currentDrawing.Modify(); }