Our designers will be printing individual color separations to a Device Independent Postscript File. We want to capture the name of each color separation by executing the following code:
Private Sub GlobalMacroStorage_DocumentAfterPrint(ByVal Doc As Document) Dim sColor as string sColor = ActiveDocument.PrintSettings.Separations.Plates(1).Color 'Log the color separation name to a file... End Sub
(FYI: I am able to successfully write to a log file from within the "QueryDocumentPrint()" event procedure.)
CorelDRAW X5 crashes when I try to do almost anything in the "GlobalMacroStorage_DocumentAfterPrint()" event procedure.
Can anyone help?
Thanks,Allan Kisner
Code below print color separations to single files, each file named by test-number o plate-color_name.ps
I hope it's something you can start with.
Sub SepToFile()
With ActiveDocument.PrintSettings
.SelectPrinter "Device Independent PostScript File"
.Options.ObjectsColorMode = prnObjectsNative
.Separations.Enabled = True
.Separations.incolor = False
.PrintToFile = True
.FileMode = prnSeparatePlates
.ForMac = False
.FileName = "D:\test.ps"
With .Prepress
.InfoWithinPage = False
.FileInfo = True
.CropMarks = False
.RegistrationMarks = False
.ColorCalibrationBar = False
.DensitometerScale = False
End With
ActiveDocument.PrintOut
End Sub
Best regards
Mek