OberonPlace.com Forums  

Go Back   OberonPlace.com Forums > Developer Forums > VBA > CorelDRAW/Corel DESIGNER VBA

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 21-07-2004, 10:09
Rick Randall
Guest
 
Posts: n/a
Default macro to export an svg or svgz

Hi-I have a macro that converts a .cdr file into a few different formats. I want to add the ability to export an .svg or .svgz file. Everytime I try I get an automation error. Any help would be appreciated. ---Rick

Here's my code:

Code:
    Dim expflt As ExportFilter
    Dim expopt As StructExportOptions

    ActiveDocument.ClearSelection
    Set expopt = New StructExportOptions
    expopt.UseColorProfile = False
    Set expflt = ActiveDocument.ExportEx("C:\test.svgz", cdrSVGZ, cdrAllPages, expopt)
    expflt.Finish
Reply With Quote
  #2  
Old 18-08-2004, 22:05
Alex's Avatar
Alex Alex is offline
Administrator
 
Join Date: Nov 2002
Posts: 1,940
Blog Entries: 4
Default Re: macro to export an svg or svgz

Rick,

Are you sure you have SVGZ filter installed during CorelDRAW setup? Can you export to this format manually in CorelDRAW?

I just tried your example in both CorelDRAW 11 and CorelDRAW 12 on my machine and both worked fine. Here is the exact code I run:

Code:
Sub SaveToSVGZ()
    Dim expflt As ExportFilter
    Dim expopt As StructExportOptions

    ActiveDocument.ClearSelection
    Set expopt = New StructExportOptions
    expopt.UseColorProfile = False
    Set expflt = ActiveDocument.ExportEx("C:\test.svgz", cdrSVGZ, cdrAllPages, expopt)
    expflt.Finish
End Sub
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding a Reference on a pwd protected macro Rick Randall CorelDRAW/Corel DESIGNER VBA 9 27-10-2004 09:27
An Idea for a handy and easy to make macro vallentin Macros/Add-ons 2 16-03-2004 11:35
Problem with Export (or Save as) in AI-Format LOT CorelDRAW/Corel DESIGNER VBA 3 10-02-2004 14:28
New macro to clip curves w.r.t. a border Gerard Hermans Macros/Add-ons 0 09-06-2003 07:50
Speeding up a macro Rick Randall CorelDRAW/Corel DESIGNER VBA 2 12-12-2002 10:51


All times are GMT -5. The time now is 12:32.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
Copyright © 2011, Oberonplace.com