Looking around I found a several solutions that works quite well.
It seems to me there are two solutions.
In this case it is possible to set the origin of the exported dxf,
but I don't see how to set the layers and line types
In this case it possible to set the layers and linetypes,
but I don't see how to set the origin of the dxf
RebaseGeometry=True has no effect
Is there any solution?
With kind regards,
Hank
Looking around I found a several solutions that works quite well.
It seems to me there are two solutions.
In this case it is possible to set the origin of the exported dxf,
but I don't see how to set the layers and line types
In this case it possible to set the layers and linetypes,
but I don't see how to set the origin of the dxf
RebaseGeometry=True has no effect
Is there any solution?
With kind regards,
Hank
Hi @h.westhuisTALMJ. That option can be specified directly within the 'Format' String when using the DataIO.WriteDataToFile method. However, if you want to specify that setting when using the TranslatorAddIn.SaveCopyAs method, you can only specify the full file name of the .INI file for it to use. That INI file specifies a portion of the export settings, then there is another XML file being specified within that INI file which dictates the rest of the export settings. These two externally referenced documents (INI file & XML file) can be seen, set, or created when doing the export manually, and using the Options button to access the two tab dialog for specifying all the possible export settings. There are two places in that dialog to specify an existing file, and a button to save your current settings to a new file. The INI file is the 'configuration' file, and is what gets created when you use the [Save Configuration...] button. You can find those two files, open them, and even edit them manually if needed, to get familiar with what settings they each control. I generally do not need to use that 'Rebase Geometry' setting when exporting DXF's for CNC purposes, so I am not super familiar with how well it may (or may not) work in both scenarios.
Edit: Also, just in case you are not familiar with it yet, when you have a Sheet Metal part open, and already have a Flat Pattern generated, you can 'activate' the flat pattern edit mode, then select the main Flat Pattern node in the model browser tree, then right-click, and choose Edit Flat Pattern Definition to access a 3 tabbed dialog where you can manipulate alignment, rotation, flip alignment or sides, change (or ignore) punch representation, and change how bends are reported. While that same node is still selected, you can also choose 'Save Copy As...' from the right-click menu, which will open normal Save As dialog (with Options button greyed out), but after you click Save, a secondary dialog will show before it actually saves, which is where you can specify most of these settings, including the one you are interested in. Once you have all the settings the way you want, use the Save Configuration button, then take note of the path and file name of the INI file it creates (or updates), so you can specify that in the SaveCopyAs code, if going that route later.
Wesley Crihfield
(Not an Autodesk Employee)
Hi @h.westhuisTALMJ. That option can be specified directly within the 'Format' String when using the DataIO.WriteDataToFile method. However, if you want to specify that setting when using the TranslatorAddIn.SaveCopyAs method, you can only specify the full file name of the .INI file for it to use. That INI file specifies a portion of the export settings, then there is another XML file being specified within that INI file which dictates the rest of the export settings. These two externally referenced documents (INI file & XML file) can be seen, set, or created when doing the export manually, and using the Options button to access the two tab dialog for specifying all the possible export settings. There are two places in that dialog to specify an existing file, and a button to save your current settings to a new file. The INI file is the 'configuration' file, and is what gets created when you use the [Save Configuration...] button. You can find those two files, open them, and even edit them manually if needed, to get familiar with what settings they each control. I generally do not need to use that 'Rebase Geometry' setting when exporting DXF's for CNC purposes, so I am not super familiar with how well it may (or may not) work in both scenarios.
Edit: Also, just in case you are not familiar with it yet, when you have a Sheet Metal part open, and already have a Flat Pattern generated, you can 'activate' the flat pattern edit mode, then select the main Flat Pattern node in the model browser tree, then right-click, and choose Edit Flat Pattern Definition to access a 3 tabbed dialog where you can manipulate alignment, rotation, flip alignment or sides, change (or ignore) punch representation, and change how bends are reported. While that same node is still selected, you can also choose 'Save Copy As...' from the right-click menu, which will open normal Save As dialog (with Options button greyed out), but after you click Save, a secondary dialog will show before it actually saves, which is where you can specify most of these settings, including the one you are interested in. Once you have all the settings the way you want, use the Save Configuration button, then take note of the path and file name of the INI file it creates (or updates), so you can specify that in the SaveCopyAs code, if going that route later.
Wesley Crihfield
(Not an Autodesk Employee)
Can't find what you're looking for? Ask the community or share your knowledge.