Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Reprinting spoolfile not possible on some printers?

11 views
Skip to first unread message

Ton van Baalen

unread,
Aug 7, 2008, 5:17:35 AM8/7/08
to

I made a small program (in Delphi) to reprint spool files from the windows XP printer spooler. I used the Windows API (units WinSpool and Printers), more specifically the AddJob, GetJob, SetJob, ScheduleJob and EnumJob API calls to get things done. Using the _JOB_INFO_1A record structure.

My problem is that one printer is accepting the reprinted file (a Samsung ML 1610) and a number of other printers do not print the file. I can see the file get into the print queue where it looks like to be printed, but only an initial reset of the printer is done, nothing is printed. What I noticed is that in the queue the number of paged was "n/a", so i tried to set it via SetJob where I also altered the document name. The strange thing is that the document name is passed to the name of the queue entry, but the total number of pages is not. Also when after the SetJob and ScheduleJob calls the jobdata is retreived with the EnumJobs call, the total number of pages is reset to 0 (I had set it to 1) and the number of pages printed (was 1) and I set it to 0 succeeded.

I am open to any idea that can explain this, so please help me out.

rejj

unread,
Aug 7, 2008, 5:42:11 AM8/7/08
to
I am only guessing here but aren't spool-files specific to the driver
they where created with ?

So a certain spool-file would only work with a language compatible
printer/driver.

/ Christoffer

0 new messages