plot to pdf using pdfcreator driver

plot to pdf using pdfcreator driver

gotMorris
Enthusiast Enthusiast
2,134 Views
2 Replies
Message 1 of 3

plot to pdf using pdfcreator driver

gotMorris
Enthusiast
Enthusiast

I used this as a example. I am needing a better quality pdf and am getting it using the PDFCreator driver. However I am needing to control the name and location of the pdf in code. I can do this with the standard dwg to pdf driver from autoCad but the quality stinks. If I replce the name "PDF to DWG .pc3"with "PDFCreator" the program finishes but it can't be opened because of an error. The file appears to be the correct size so the data is there. Any ideas?

 

 

acPlSetVdr.SetPlotConfigurationName(acPlSet, "PDFCreator", "Tabloid");

 

0 Likes
Accepted solutions (1)
2,135 Views
2 Replies
Replies (2)
Message 2 of 3

moogalm
Autodesk Support
Autodesk Support

Hi.

 

Have you verified interactively using the driver configuration autocad, I mean did you set plot configuration to this driver and checked.

 

Can you share the location of the driver, I will try to investigate.

0 Likes
Message 3 of 3

gotMorris
Enthusiast
Enthusiast
Accepted solution

I found the answer here. I used PdfCreator's CMO Interface to capture the pdf in its JobQueue. Then processed the pdf further.

        var jobQueue = new Queue();
            jobQueue.Initialize();
            try
            {
                PlotDWG(acPlInfo, acLayout, Dwg, pdfName);

                if (!jobQueue.WaitForJob(10))
                    log.Error("The print job did not reach the queue within 10 seconds");
                else
                {
                    //All jobs are now in your job queue
                    var printJob1 = jobQueue.GetJobByIndex(0);
                    printJob1.SetProfileByName("drafting");
                    printJob1.ConvertTo(pdfName);
                }
            }
            finally
            {
                jobQueue.ReleaseCom();
            }
0 Likes