I would like to export my 3D drawing (Sheet metal) made in NX 10 to 2D dxf file. I made plenty of similar parts before and they were working, then I had to reinstall NX and now I am not able to export them.
After creating a 3D draw I set FRONT view and I make "Flat Solid" from it, then I hide all previous steps in command menu on left.
After that I try to export it by using following options:
Input and output: displayed part, DXF, 2D
Data to export: Model data- Selected object, click on object, Selected View
Options: 2004, Spline, check Remove overlapping entities
Another lists I keep unchanged.
After I click Finish, cmd table will appear and after about 1 minute it will pop up that NX Component stopped working.
I am also sending you some pictures.
Can anyone help me please?
Nothing is more frustrating than searching a forum and finding a post like this where you know someone solved the problem you are having, but did not take the time to document how.
it has a been a long time since I worked with this code so I apologize if it is messy. I wrote something similar for exporting dxf files
def export_DXF(self): global slicelist slicelist= features=workPart.Features
############export dxf############### dxf_cntr=0 for feature in features: theLw.Open() theLw.WriteLine("Slice list Journal name is " + feature.JournalIdentifier) theLw.WriteLine("Feature name is " + str(feature.GetFeatureName)) slicelist.append(feature) dxf_cntr+=1 theLw.WriteLine("Dxf counter " + str(dxf_cntr)) temp_index=1 for slicelayer in range(3, dxf_cntr-1): dxfdwgCreator1 = theSession.DexManager.CreateDxfdwgCreator() #use save_dir for OutputFile= dxfdwgCreator1.ExportData = NXOpen.DxfdwgCreator.ExportDataOption.Drawing dxfdwgCreator1.ViewEditMode = True dxfdwgCreator1.FlattenAssembly = True dxfdwgCreator1.OutputFile = str(save_dir) dxfdwgCreator1.ExportData = NXOpen.DxfdwgCreator.ExportDataOption.Modeling dxfdwgCreator1.ExportSelectionBlock.SelectionScope = NXOpen.ObjectSelector.Scope.SelectedObjects dxfdwgCreator1.ObjectTypes.Curves = True dxfdwgCreator1.ObjectTypes.Surfaces = True dxfdwgCreator1.ObjectTypes.Solids = True dxfdwgCreator1.ObjectTypes.Annotations = True dxfdwgCreator1.ObjectTypes.Structures = True #version of autocad dxfdwgCreator1.AutoCADRevision = NXOpen.DxfdwgCreator.AutoCADRevisionOptions.R2013 dxfdwgCreator1.ExportSplinesAs = NXOpen.DxfdwgCreator.ExportSplinesAsOptions.Polyli
ne2D dxfdwgCreator1.FlattenAssembly = False
##input file name dxfdwgCreator1.InputFile = "C:\your_partname.prt" #output file name dxfdwgCreator1.OutputFile = str(save_dir)+"test_layer"+str(temp_index)+".dxf" temp_index+=1 dxf_body=slicelist[slicelayer].GetBodies() #theLw.WriteLine("Feature name is " + str(dxf_Body)) added1 = dxfdwgCreator1.ExportSelectionBlock.SelectionComp.
Add(dxf_body) dxfdwgCreator1.WidthFactorMode = NXOpen.DxfdwgCreator.WidthfactorMethodOptions.Auto maticCalculation dxfdwgCreator1.LayerMask = "*" dxfdwgCreator1.ViewList = "Top" dxfdwgCreator1.Commit() #Slicer.saveDXF(self, section_curves[index], index) dxfdwgCreator1.Destroy()