PDA

Click to See Complete Forum and Search --> : EMF Spoolfile Viewer


Merrion
May 13th, 2005, 11:37 AM
Description
In Windows NT, 2000, XP and 2003 the printer spool file can be generated in EMF. This application allows you to view those spool files on screen. This is useful if you want to see what has been printed out on a printer.

To save the spool files, select the printer in control panel and in the properties screen select the checkbox "Keep printed documents".


System Requirements
Requires the .NET framework and the spool files must be generated on Windows NT, 2000, XP or 2003.

wayneh
Sep 18th, 2007, 02:59 PM
Hi -

I'm having an issue where a file printed from my application takes about 3 minutes to come out of a printer, but the same file printed from another (commercial) application takes less than 20 seconds.

The printer spool files are created in about the same amount of time.

Do you have any ideas as to what can cause this?

I have captured 2 SPL files, one mine and the other form the other app.
I can view them with your viewer fine, but I'm much more interested in
header info, etc.
Do you have a way for me to see that info?
(I don't use .NET - I use VB 6 so I can't use your viewer code unfortunately...)

Thanks.

Merrion
Sep 19th, 2007, 08:10 AM
The spool header file (*.shd) is documented here (http://www.codeproject.com/printing/SpoolShadowFile.asp) - the code is .NET but the structure is readily converted to VB6 (I think)

wayneh
Sep 19th, 2007, 08:58 AM
Any ideas on why one app's spool file will process so much faster than another, given that they have the same contents?

Thanks for the link too.

Merrion
Sep 19th, 2007, 09:00 AM
are they exactly the same content - i.e. if you do a file diff on the two spool files they are the same?

wayneh
Sep 19th, 2007, 09:44 AM
No, the content isn't exactly the same which is why I want to 'decode' the files and see what's in them.

The image content is the same, but even opening the binary files in wordpad I can see differences in the headers since they came from two different apps.

I've uploaded them if you want to see what you can see....

I can't understand why one file "avspool.spl" prints in about 20 seconds, but the other "vlspool.spl" takes up to 3 minutes.
Both are created on the same machine and take about the same time to make the spl file, even though the files sizes are different.

Merrion
Sep 19th, 2007, 01:46 PM
OK - I will add some code to analyse the actual EMF records tomorrow.

The basic differences are:
VLSpool = 9652 EMF records, 287680 bytes
AVSpool = 8218 EMF records, 147716 bytes

wayneh
Sep 19th, 2007, 02:42 PM
Thanks - that's very kind of you.

Merrion
Sep 20th, 2007, 06:36 AM
Right ho - summary attached...

The main difference seems to be that VLSpool creates 290 font objects whereas AVSpool creates only 2. The creation and deletion of these font objects is what is slowing the print down...

wayneh
Sep 20th, 2007, 08:47 AM
That's quite interesting but quite odd.

In most cases, the VL documents print quite fast - normally, in fact.

The document uses the same 2 fonts in multiple places.
Is it possible that the printer (Driver) is downloading a font for each font object, whereas other printers/drivers would only download the two fonts one time?

Can this be tested somehow?

Can I find out how you determined the records for these spl files?

wayneh
Sep 20th, 2007, 09:02 AM
Sorry - one more question -

If the font creation was the issue, wouldn't it take about the same time on any printer? Or more precisely, wouldn't the VL file always take a lot longer to print than the AV file regardless of the printer used?
And then, couldn't you (or I) test this simply by viewing the two files and printing them to our own printers?