Quantcast
Channel: CorelDRAW Community
Viewing all articles
Browse latest Browse all 7339

Export to JPG Macro

$
0
0

Hi.

Shown below is a little macro I am creating to open a CDX6 file then export it to jpg. I am unable to get the export option to work. I am able to successfully open the CDX6 file.

Please note, I am needing to run this script outside of Corel Draw.

___________________________________________________________________________________

Const FileSystemObject = "Scripting.FileSystemObject"
Const CorelDraw = "CorelDraw.Application"
Const TestFile = "\\Atlas\home\dmarkey\SIGNAGE MANAGEMENT\Signage_2009\Tender\Sign_Drawings\Final\Temp2\ad3.cdr"

Dim Software
Dim fso
Dim SourceFolder

Set fso = CreateObject(FileSystemObject)
Set Software = CreateObject(CorelDraw)

With Software.OpenDocument(TestFile)
      .Activate
      .Unit = cdrMillimeter
            With .Export
                         .StructExportOptions "\\Atlas\home\dmarkey\SIGNAGE MANAGEMENT\Signage_2009\Tender\Sign_Drawings\Final\Web_Files\Display\ad3.jpg", cdrJPEG, 1, 0, Nothing
            End With

End With


Viewing all articles
Browse latest Browse all 7339

Trending Articles