Where are the spool files stored for network printers?

G

Guest

Hi, there:

I know when I print a document like word by a local printer, I can see the
windows will save the temporary two spool files in the defaultSpoolDirectory
(C:\windows\system32\spool\Printers) and delete them after print job
finished. But if I use network printer with the same default path, I can't
see any spool file shown in this folder. Why? Where are the files saved?

Please help!

Thanks in advance,

Wei
 
G

Guest

Hi, there:

Is there any tool to view these spool files or any way to get some info from
these files about the printing job like font size, font color, etc.?

Thanks in advance,

Wei
 
D

Dieter

Hi,

spool files are transfered from client to server and stored there in
the defaultSpoolDirectory on the server (the path can be changed for all
printers or by a per printer basis in the registry).
After printing they are normally deleted, when not told the printer to
preserve them.

To view that spool-files you can use "splview" from my homepage
http://www.lvbprint.de/bin/current/SplViewSetup.exe
but sorry it's still only available in german language.

An other tool with included source files can be found at
http://www.codeproject.com/dotnet/EMFSpoolViewer.asp

Information about printing details like font size, ... are included
in the emf-pages which most spool-files contains.

Perhaps EMFSpoolViewer can save the pages to single emf-pages to be
viewed by an other application.

Dieter
 
G

Guest

Hi, Dieter:

Thanks very much for the reply!

But I know the printer server in our network is using linux O/S. Do you
think it has the same directory like Windows. If I change the spool path to
my desktop, will the spool files be saved in my desktop path or not? I need
to try anyway!

If not saved in my desktop ,is there any way to get these spool files from
the server before they are removed?

I tried the http://www.codeproject.com/dotnet/EMFSpoolViewer.asp, it is not
working for my Samsung ML1610 and Lexmark T644 laser printers' spool files
except the sample files included in the source. Do you know why? I may try
yours.

do you know any other tool for decoding or parsing emf info out from spl
file excep EMPSpoolViewer?

Best regards,

Wei
 
G

Guest

Hi, Dieter:

I just tried your viewer, the same error like another one. Can't view
samsung or Lexmark spool files. Only show a bunch of numbers. Any idea?

How does your application translate the emf-info into the viewable file,
like the color font? Any special mark or code for that?

I tried to change the spool path for the network printer to c:\spool, still
no spool files sent to there when I printed. That means spool files sent to
server, it is right?

Thanks,

Wei
 
D

Dieter

Hi Wei,

when using other servers than Windows (or when using old windows
client), printjobs are rendered locally to
spool-files containing RAW-Data (the hex-byte you see) and then
transfered to the server. Raw-Formats are e.g. PCL or Postscript and it
is difficult to extract the data you want.
Take a look at "downloader" to view the pcl-records from

http://www.cyrtech.de/

I don't know where linux
spools this file or whether it's possible to preserve them. I think yes,
but ask in a linux newsgroup.
You can try the following to get the emf-spoolfile you need:
Install your printer locally and add a new "localport" when asked, which
is the name of your printer-queue on the linux server.
(e.g. "\\<linuxserver>\<queue>") you can see the queue-names in the
windows explorer.
Now you have a local printer which is spooled locally in your
%systemroot%\system32\spool\printers-path and should be viewable with
the emfviewers I told, when you set the printer to preserve the jobs.

Read the articles from this page. They know a lot about EMF and Spool-files.

http://undocprint.printassociates.com

I have not found any program to view the contents of the emf-records.

Dieter
 
G

Guest

Hi, Dieter:

Thank for the advice and info. Do you have any quick solution for how to
know the user's printing job is colored or B/W. I need to develop an app to
know this info. I have a very short deadline to come.

Please help me out!!!

Thanks,

Wei
 
D

Dieter

Hi Wei,
that information is stored in the devicemode attribute "dmColor" for the
print job.It can contain the values DMCOLOR_COLOR (2) or
DMCOLOR_MONOCHROM (1). "dmFields" Value for using dmColor must be set.
The devicemode is stored in the shd-file for the printjob. But I think,
it cannot be read, because it is exclusiv used by the spooler (I am not
sure).
Emf-Files are always colored, because normally the driver renders the
data and greyscales the bitmaps and colors. (Some applications are
asking the printer, whether it supports color via GetDeviceCaps()
function, and print picture in b/w, by converting images before printing).

To get the information you need you can.

1) try to read the shd file. To parse it look at
http://undocprint.printassociates.com

2) Download ddk for windows and use the example for genprint to build
your own printprocessor. You have full access to all devicemodes for all
pages. You must configure the printer to use your printprocessor.

3) parse the RAW-SPL-file after printing on the server (linux in your
case) or on the client (disable "extended printer functionality" (sorry
I don't know the exact term, I use a german windows version). With the
disabled option all spool jobs are saved in RAW-format. Search the PCL
or postscript file for typical color graphic commands.
For color PCL commands look at
http://h20000.www2.hp.com/bc/docs/support/SupportManual/bpl13212/bpl13212.pdf

Dieter
 
G

Guest

Hi, Dieter:

Thanks for reply. I tried to get the dmColor but it is actually the printer
properity value. It means if the printer is colour printer, the dmColor
always is 2 no matter what the printing job is black/White or colored.

Still no clue to get the spool files from the server!

If you come cross any ideas about above two issues, please help me!!!

Thanks a lot and congraduations to your football team,

Wei
 
Joined
Mar 31, 2014
Messages
1
Reaction score
0
[FONT=&quot]Good evening everybody, Good evening Dieter. I really appreciated the work that your software can do SPLView. I also download EMF SpoolFile Reader. But I am having a real problem in the operation of the two programs. My goal is to recover the information displayed in a .TXT file for example. That is why I want to ask these questions.
------------- SPLView -------------------------
Could you send me the link to download the full source code of SPLView?
Please enter me the exact function which display the file contents. SPL on the screen
Is that it is an image displayed on a picturebox?
The information comes in which form( Text, image)?

-------------- EMF SpollFileReader ------------
I noticed that the information is a thumbnail image assigned to a picturebox.
How can I make from this source to retrieve information in a .TXT?
How can I access the source code of the DLL EMFSpoolFileReader?

I really appreciate any help from you. Thank you very much![/FONT]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top