Truncated device attribute from printer.dll

From: Bob Halpin (halpin_at_qwpage.com)
Date: 02/28/04


Date: Sat, 28 Feb 2004 06:35:17 -0500

Hi,

I'm using Michael Schwartz's printer package and have an odd behaviour
difference between two machines.

Here's the behaviour on the 'bad' machine:

% load printer.dll
0.9.6.11
% package require registry
1.1.1

(get the list of installed printers)

% ::registry values {HKEY_CURRENT_USER\Software\Microsoft\Windows
NT\CurrentVersion\Devices}

{Generic / Text Only} {\\WHATEVER\HP LaserJet 3300 Series PCL 6}

(pop up the printer select dialog, and chose the Laserjet)

% printer dialog select
0x121053e 1

(get that printer's attribute list)

% printer attr 0x121053e
{copies 1} {copiesToSpool 1} {device {\\WHATEVER\HP LaserJet 3300 Se}}
{driver winspool} {hDC 0x121053e} {{page dimensions} {8500 11000}}
{{page margins} {1000 1000 1000 1000}} {{page minimum margins} {166 166
<snip>

The weirdness is the truncated device attribute. As you can see, it's
chopped in the middle of the word 'Series'. Here it is again:

% printer attr -hDC 0x121053e -get device
{device {\\WHATEVER\HP LaserJet 3300 Se}}

This truncation doesn't happen on a different system (on different
network, different printers, etc.) For reasons I can probably work
around, this is causing me some grief. Does anyone have any idea why it
happens though?

Thank's,

Bob