cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need help navigating or using the PTC Community? Contact the community team. X

Batch transfer to stp or igs

HL_9618737
2-Guest

Batch transfer to stp or igs

I am using Creo Parametric 4.0 M110

如何批量将CREO模型(part,assembly)转为stp或igs文件?
如何批量将CREO的drawing批量转为dwg或dxf文件?

--------------------------------------------

How to batch convert CREO models (part, assembly) into stp or igs files?
How to batch convert CREO drawings into dwg or dxf files?

3 REPLIES 3
jchelle
15-Moonstone
(To:HL_9618737)

Hi HL_9618737 

 

In order to translate Creo Parametic files into STEP, IGES , DWG or DXF I propose you to check the article CS139340 Creo Parametric Pro/BATCH ,Distributed Pro/Batch and Distributed Computing Central Resource Page.

 

If you need more help, please do not hesitate

 

Jean Claude 

Hidetaka
14-Alexandrite
(To:HL_9618737)

Batch convert can easily be done with AutoHotkey.

For example, this is how I export multiple files to dxf. (convert to pdf, step, etc, or physically print would be similar.)

 

1. First, create a list of files to be converted. 

To do this, I use a template assembly drawing which includes Bill of Materials (a repeat region).

If I want to exclude some file from being converted, I can filter the repeat region by rule or by item.

After the list of files is done, I will export it to a .txt file.

Note that it is possible to make mapkeys to do all the above automatically. The only step that needs to perform manually is filtering the list.

 

2. Second and final step is using an Autohotkey script to read the txt file created in step 1, then repeatedly export to stp, pdf, dxf, etc, or print, until the end of the file list is reached. 

 

Below is sample ahk code to batch export dxf (exporting models to stp or iges files would be almost the same).

 

^!d::
; Control Alt + d : Export a list of drw to dxf --------------------
; get active part's folder name
WinGetActiveTitle, Title
if (Title = "Creo Parametric")
{
MsgBox,,Invalid Start Window, Please run this function when a model in working directory is active.`nTry opening a Creo file and then type Right Alt + D again., 10
return
}
folderStart := InStr(Title,A_Space,,,2)
StrReplace(Title,"\",,count)
folderEnd := InStr(Title,"\",,,count)
folderName := SubStr(Title,folderStart+1,(folderEnd-folderStart))
; exclude the first space but include the last slash
; clipboard := folderName
printList := folderName . "autoprint_drw_list.txt"

MsgBox, 6, Batch Export Confirmation, Export all drawings in export/print list to DXF?,10
; MsgBox option 6, Cancel/Try Again/Continue
IfMsgBox Cancel
Return
IfMsgBox TryAgain ; edit export (print) list
{
MsgBox,,Edit dxf drawing list, Please edit the drawing list and print again, 10
Run, %printList%
Return
}
IfMsgBox Timeout
Return

SetTitleMatchMode, 2 ; detect windows in mode 2 - containt wintitle anywhere inside to be a match

Loop, read, %printList%
{
;DrwName := A_LoopReadLine . ".drw"
;MsgBox % DrwName
DrwName := SubStr(A_LoopReadLine,1,InStr(Title, A_Space)-1) . ".drw"
;MsgBox % DrwName
SendInput ^o%DrwName%{Enter} ;open drawing
WinWaitActive,.drw,, 5 ; wait until the drawing is opened to perform print action
SendInput edf2
; edf2 is the mapkey to export dxf
Sleep 1000
}
FileRead, printList, %printList%
MsgBox,,Dxf export completed, The following drawings have been exported: `n%printList%,10 ; final confirmation
return

Top Tags