Hier der Code
SldWorks swApp = new SldWorks();
swApp.Visible = true;
string filePathSource = @"C:\Users\ChristophBraun\Desktop\SolidWorks\Test.SLDPRT";
string filePathTarget = @"C:\Users\ChristophBraun\Desktop\SolidWorks\Test123.DXF";
int err = 0;
int warn = 0;
ModelDoc2 swDoc = swApp.OpenDoc6(filePathSource, (int)swDocumentTypes_e.swDocPART,
(int)swOpenDocOptions_e.swOpenDocOptions_Silent, "", ref err, ref warn);
PartDoc swPart = (PartDoc)swDoc;
ModelView myModelView = null;
myModelView = ((ModelView)(swDoc.ActiveView));
bool boolstatus = swDoc.Extension.SelectByID2("Importiert1", "BODYFEATURE", 0, 0, 0, false, 0, null, 0);
System.Console.WriteLine(boolstatus);
bool ret = swPart.ExportFlatPatternView(filePathTarget, (int)swExportFlatPatternViewOptions_e.swExportFlatPatternOption_RemoveBends);
Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP