Cancel
Showing results for 
Search instead for 
Did you mean: 

Batch Export of PSM files to DXF

Phenom
Phenom

I updated my old batch DXF exporter to work a bit better. I know it was useful to a few people here. It takes all sheet metal files in a folder and automatically exports a DXF flat pattern for each.

 

Instructions:

-Start Solid Edge and open any file in a project folder. (assembly, part, sheetmetal, does not matter)

-Run the exe. You can do this one of three ways- Double click on the file OR go to File/Tools/Run Macro in Solid Edge OR customize your ribbon, change the Choose Commands From dropdown to Macro, navigate to where you have downloaded the macro, and add it to your toolbar of choice.

-The macro will look in the folder for all .PSM files and export them to .DXF if a flat pattern exists. If a flat pattern does not exist, it will list the filename and exit. It will NOT look in subfolders. It gives a status in a console window.

-Exported DXF's will be located in a created subfolder called DXF.

 

 

Notes:

-Tested with ST7-ST9

-Now recognizes when no flat pattern exists and warns the user, instead of creating a blank DXF

-Now correctly uses OleMessageFilter, crashes much less often

 

Attached is the file. You cannot attach an .EXE here, so please rename it from .txt to .EXE after downloading.

-Dylan Gondyke
3 REPLIES

Re: Batch Export of PSM files to DXF

Gears Honored Contributor Gears Honored Contributor
Gears Honored Contributor

Hi Dylan,

 

I have a sheetmetal part open in Solid Edge and run the app.

It gives a message:

 

PSMDXFMSG.png

Re: Batch Export of PSM files to DXF

Phenom
Phenom

Hi Tushar. Do you perhaps have two instances of Solid Edge running? I don't check for that. Here's a screenshot of the pertinent code- please excuse the simplistic nature. Open to any suggestions.

 

File In Directory.PNG

-Dylan Gondyke

Re: Batch Export of PSM files to DXF

Gears Honored Contributor Gears Honored Contributor
Gears Honored Contributor

Hi Dylan:

 

That seems to be the case for I can reproduce the error again only by starting two instances of Solid Edge.

 

~Tushar