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

Implement export of Creo drawing to WMF/EMF format

Implement export of Creo drawing to WMF/EMF format

Implement export of Creo drawing to WMF/EMF format. This way you enable users to put nice pictures into Service Guides (created using Microsoft Word) of their products.

Notes:

  • WMF/EMF file will contain vector image of drawing view or drawing sheet
  • User can import WMF/EMF file into Word document

Additional requests:

  • Use pentable during export

Export options:

  • Option no.1: Export every sheet into separate file
  • Option no.2: Export every view into separate file

Martin Hanak

8 Comments
fmueller
3-Visitor

Just try print to CGM-file. This might be a workaround so far.

MartinHanak
23-Emerald V

Hi Frieder,

just a simple question ...

Have you ever used CGM file to create nice Service Guide using Microsoft Word ?

What is your experience ?

Are you sure that picture quality is excelent ?

... OR ... Is your asnwer just suggestion what can I try ?

Best regards

Martin Hanak

fmueller
3-Visitor

I have used it before, when I wanted b/w line graphs from a proE-drawing in Word. I made

a cgm.pcf plotter definition file with the following content

plotter cgm

button_name CGM-File

button_help CGM Vektor-Graphics for Word

delete_after_plotting no

interface_quality 3

pen_table_file $CREO_CFG_LW\config\plot\ps.pnt (you will need to change that line to your correct pentable file)

plot_drawing_format yes

plot_destination file default

PLOT_FILE_DIR .\plot (we always have a subfolter .\plot]

plot_names yes

regards

Frieder

MartinHanak
23-Emerald V

Hi Frieder,

what ProE version did you use ?

Best regards

Martin Hanak

MartinHanak
23-Emerald V

Information concerning CGM file import

As explained in http://technet.microsoft.com/en-us/security/bulletin/MS10-105 CGM files are vulnerable. MS therefore blocked CGM import in MS Office suite (I reproduced this setting in MS Word 2003/2010).

As explained in http://support.microsoft.com/kb/2479871/en-us user can enable CGM import by Registry modification - it is necessary to set AllowListEnabled to 0.

I tested the registry trick in MS Word 2003/2010 successfully.

Martin Hanak

fmueller
3-Visitor

ok, that might explain something. I used it a while ago with Wildfire3 and an older Office version, where we had to install the CGM-Importfilter separately. Now with the actual Creo2 the CGM-export is still working but the Word import didn't work anymore. Let's see if your link changes the MS-Office bahaviour.

regards

Frieder

fmueller
3-Visitor

After doing the following registry entries it works now with Office2010 and CGM-files from Creo2.0:

for a XP64bit the following registry file will change the MS-Office bahaviour:

enable_cgm_office_import.reg

code:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Office\Common\Security\AllowLists\GraphicsFilterImport]

"AllowListEnabled"=dword:00000001

"CGMIMP32.FLT"="2003.1100.8249.0"

"EPSIMP32.FLT"="2003.1100.8314.0"

"GIFIMP32.FLT"="2003.1100.8327.0"

"JPEGIM32.FLT"="2003.1100.8327.0"

"PICTIM32.FLT"="2003.1100.8249.0"

"PNG32.FLT"="2003.1100.8329.0"

MartinHanak
23-Emerald V

IMPORTANT NOTE:

Value set in CGMIMP32.FLT variable (eg. 2003.1100.8249.0) must match with the version of CGMIMP32.FLT file (in Windows 7 64bit + Office 2010 this file is located in C:\Program Files (x86)\Common Files\microsoft shared\GRPHFLT directory).

To get info about file version, you can create text file test_ver.vbs, put the following code into it and launch it. You will get test_ver.txt file.

Option Explicit
Dim fso, fc, f, fs 
Dim strPath, strFile, adresar_s_filtry

'On Error Resume Next

adresar_s_filtry = "C:\Program Files (x86)\Common Files\microsoft shared\GRPHFLT"

strPath = "test_ver.txt"

Set fso = CreateObject("Scripting.FileSystemObject")

Set strFile = fso.CreateTextFile(strPath, True)

strFile.WriteLine("FileName,Last Modified,File Version")

Set f = fso.GetFolder(adresar_s_filtry)         
Set fc = f.Files
For Each fs In fc
  If fso.GetExtensionName(fs) = "FLT" then
   strFile.WriteLine(fs.Name & "," & fs.DateLastModified & "," & fso.GetFileVersion(fs))
  End if
Next

Best regards

Martin Hanak