Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Mar 11th, 2013  |  syntax: None  |  size: 0.81 KB  |  views: 353  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. PDFCreator.clsPDFCreator creator = new PDFCreator.clsPDFCreator();
  2. PDFCreator.clsPDFCreatorOptions options = new PDFCreator.clsPDFCreatorOptions();
  3. options = creator.cOptions;
  4. PDFCreator.clsPDFCreatorError perr = new PDFCreator.clsPDFCreatorError();
  5.  
  6. if (!creator.cStart("/NoProcessingAtStartup", false))
  7. {
  8.      Console.Write("Can't Initiase PDF Converter, letter Generation Error");
  9. }
  10.  
  11. options.UseAutosave = 1;
  12. options.UseAutosaveDirectory = 1;
  13. options.AutosaveDirectory = path;
  14. options.AutosaveFilename = name;
  15. options.AutosaveFormat = 6; //0=PDF, 1=PNG, 2=JPG, 3=BMP, 4=PCX, 5=TIFF, 6=PS, 7= EPS, 8=ASCII
  16. creator.cOptions = options;
  17. creator.cSaveOptions();
  18. creator.cClearCache();
  19. creator.cPrinterStop = false;
  20. creator.cDefaultPrinter = "PDFCreator";
  21. creator.cPrintFile(pathFull);
  22.  
  23. err = creator.cError.Description.ToString();
clone this paste RAW Paste Data