Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - PrintDocumentToFile - file will not release
  FAQ FAQ  Forum Search   Register Register  Login Login

PrintDocumentToFile - file will not release

 Post Reply Post Reply
Author
Message
Marvin View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Dec 12
Location: Germany
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote Marvin Quote  Post ReplyReply Direct Link To This Post Topic: PrintDocumentToFile - file will not release
    Posted: 28 Nov 13 at 9:01AM
I am helpless :) One function of my Application is to convert PDF Files to Postscript by using the PrintDocumentToFile function.
So far so good, but the file will not write to the desired destination, while my application is running.
It is shown in the windows spooler and will release if my application is stopped.

I call the printer class, that uses the QuickPdf Library, within a using-Block and in addition i use a Garbage Collect after that.

So i can't explain it to me, why the file will be released before the application stopped.
May be there is a closure missing, like CloseDoc to release the Document?

Here is a short version of my code:
private void PrintToFile()
{
   var cp = objPDF.NewCustomPrinter(_PrinterName);
   objPDF.SetupCustomPrinter(cp, 5, 1);           // Set Quality

   var iPrintOptions = objPDF.PrintOptions(_PageScaling, 1, Path.GetFileName(_PrintFileName));

   objPDF.PrintDocumentToFile(cp, _StartPage, _EndPage, iPrintOptions, _OutputFile);
}

Does anyone have any idea why this is so?

Thanks Lutz.
Back to Top
Marvin View Drop Down
Beginner
Beginner
Avatar

Joined: 11 Dec 12
Location: Germany
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote Marvin Quote  Post ReplyReply Direct Link To This Post Posted: 28 Nov 13 at 2:07PM
Hi Guys, it works!
After a upgrade from 9:14 to 9:16 version of the library it works again.
Anyone who can read, have a clear advantage
Thanks all.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store