Skip navigation
cmack13
Currently Being Moderated

Printing Files Print SPooler

Dec 2, 2011 11:01 AM

Tags: #air #adobe #print

I have a request for an application to be able to download files and print them in the background. I have written an Air Desktop application that prints any file to the default printer as long as the file is associated with an application in the OS. This solution only works with windows and I am ok with that. I am using a VBScript along with the NativeProcess method to print. I am passing in the file name and directory into the script. This works great if the default printer is setup correctly. However, if there is an error printing the file, I have no way of knowing it. I need to be able to inform the user of a printing error.

 

I am not opening the PDF in a view. This is a reporting application that basically prints reports. It is designed to run in the system tray and requires no interaction from the user. The user chooses to run this in the background so they don't have to download a report, open it and print it out manually.

 

Is there a better way to print files (XLS, DOC and PDF)?

Is there any way to get a handle to the print spooler and query it for a print status? Or some other way to find out if a document has printed correctly without using the PrintJob class?

 

Thanks in advance for any suggestions.

 

Chris M.

 

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points