printui.dll problem

Posted on 2004-11-04
Last Modified: 2006-11-17
OK, here are the Details:  I have an office setup with Win2K servers and XP Pro work stations.  On one of the servers I have created multiple print queues (some for different trays on the same printer).  I am using a script like the following to map network printers on the workstations:

REM Delete the printer if it is there
rundll32 printui.dll,PrintUIEntry /dn /q /n "\\server\US Tray2 Toshiba"
REM Map the printer
rundll32 printui.dll,PrintUIEntry /in /q /n "\\server\US Tray2 Toshiba"
REM Apply the saved settings file
rundll32 printui.dll,PrintUIEntry /Sr /q /n "\\server\US Tray2  Toshiba" /a "\\server\share\Tray2Toshiba.dat"

I created the saved settings file (Tray2Toshiba.dat) with the following:
rundll32 printui.dll,PrintUIEntry /Ss /n "\\server\US Tray2  Toshiba" /a "\\server\share\Tray2Toshiba.dat"
I did this while logged on as a user with the standard permissions that all user have (Domain Users, Local Administrator of the workstation). PS - all users have full control over the print queues.

The Problem:
When I run this script it does indeed map the printers and applies the saved settings file.  But, the settings in the saved settings file do not always take effect (i.e. - printing preferences tray select is set to auto select not Tray2 like it is supposed to be.)
The kicker is that sometimes it works and sometimes it does not.  When it does not I have to go to the PC and change the tray settings manually.  On top of that though, when I try to manually change these settings on some of the users PC who used this script, it will not save the changes.  It always goes back to auto select for the tray.

Any ideas?  I am assuming that some how it has to be a permission issue or something?
Question by:tfountain

    Author Comment

    Problem solved.
    After doing further research I found the driver to be the problem.  I was using HP's generic 8100 series PCL driver.  I downloaded the PCL6 driver for my specific printer, recreated my saved settings file and re-execute the scripts on the PC's.  It works perfectly.

    Accepted Solution

    Question answered by asker or dialog valuable.
    Closed, 500 points refunded.
    ee_ai_construct (replacement part #xm34)
    Community Support Admin

    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Join & Write a Comment

    If you have done a reformat of your hard drive and proceeded to do a successful Windows XP installation, you may notice that a choice between two operating systems when you start up the machine. Here is how to get rid of this: Click Start Clic…
    For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
    In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now