Why I can't get the correct page count?

Nov 9, 2011 at 4:32 PM
Edited Nov 14, 2011 at 12:44 PM

Recently, I got the printer monitoring component from Internet, the version of PrinterQueueWatch.dll is I used this component in my C# application to monitor a printer(HP Laser Jet CP 5225) in our Intranet.

I found a serious problem: when I printed a Microsoft PowerPoint 2007 file, I debuged that the value of copies and totalpages are alway 0! I have tested to print a Word 2007 file and other file, the value of copies and totalpages are correct. I am confused how this could happen?

Has anyone meet the problem like this?

Jun 1, 2012 at 6:02 PM
Old question but i thought i would post an answer which may help others facing similar issues.
I had a similar problem before and i solved my issues by doing a sum of PagesPrinted and TotalPages. What is happening in this case,
especially with large documents, is that some printers will start printing the document whilst is it is still spooling. The result of 
this is that for every page that the printer has printed the value of TotalPages will decrease and PagesPrinted will increase.
Hope this helps.