+ Post New Thread
Results 1 to 5 of 5
Scripts Thread, installing network printer based on pc name in Coding and Web Development; Hi guys, I am trying to use the following logon script; IF %COMPUTERNAME:~0,3%==IT- rundll32 printui.dll PrintUIEntry /q /in /n "\appsserver\ICTLaser" ...
  1. #1

    Join Date
    Feb 2007
    Posts
    363
    Thank Post
    174
    Thanked 38 Times in 34 Posts
    Rep Power
    40

    installing network printer based on pc name

    Hi guys,

    I am trying to use the following logon script;

    IF %COMPUTERNAME:~0,3%==IT- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\ICTLaser"

    IF %COMPUTERNAME:~0,3%==S5- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\S5Laser"

    IF %COMPUTERNAME:~0,6%==MEDIA- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\MediaLaser" rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\AdminLaser"

    IF %COMPUTERNAME:~0,8%==LIBRARY- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\LibraryLaser"

    IF %COMPUTERNAME:~0,11%==TECHNOLOGY- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\TechnologyLaser"

    IF %COMPUTERNAME:~0,12%==LEARNINGSUP- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\S5Laser" rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\StaffLaser"

    IF %COMPUTERNAME:~0,10%==GEOGRAPHY- rundll32 printui.dll PrintUIEntry /q /in /n "\\appsserver\S5Laser"

    This works great and installs the required printer based on the PC name that the user is logging on to. The only problem is that there is a 'installing printer' box. I would prefer it to install silently so that the pupils do not click on cancel. Can anyone help?

  2. #2
    Diello's Avatar
    Join Date
    Jun 2005
    Location
    Kent, England
    Posts
    1,067
    Thank Post
    118
    Thanked 228 Times in 128 Posts
    Rep Power
    75
    The wiki is your friend Printer Addition Based on Location

  3. Thanks to Diello from:

    Ric_ (2nd December 2008)

  4. #3

    Join Date
    Jan 2007
    Location
    Enfield, London
    Posts
    159
    Thank Post
    7
    Thanked 3 Times in 3 Posts
    Rep Power
    18
    Quote Originally Posted by dgardner View Post
    This works great and installs the required printer based on the PC name that the user is logging on to. The only problem is that there is a 'installing printer' box. I would prefer it to install silently so that the pupils do not click on cancel. Can anyone help?
    For some reason the printui.dll seems to ignore the /q which is meant to install the printer quietly.

    Your best option for invisble installation is a proper scripting language like VB Script or KiXtart

  5. #4

    Join Date
    Feb 2007
    Posts
    363
    Thank Post
    174
    Thanked 38 Times in 34 Posts
    Rep Power
    40
    Thank you to both of you for responding. I am experienced with batch files etc, but I am a complete novice with VBS. Has anyone carried out this sort of installation before?

  6. #5


    Join Date
    Oct 2006
    Posts
    3,414
    Thank Post
    184
    Thanked 356 Times in 285 Posts
    Rep Power
    149
    Look at the Wiki, it "just works", only on windows though

    Seriously, if you have any experiance of a CLI you couldnt possibly go wrong with the scripts provided.



SHARE:
+ Post New Thread

Similar Threads

  1. Automatic Printer Selection - based on colour/mono/paper size?
    By Jamman960 in forum New Project Ideas
    Replies: 4
    Last Post: 23rd September 2008, 09:28 AM
  2. help with installing printer
    By mikeymike in forum Educational Software
    Replies: 19
    Last Post: 19th March 2008, 03:14 PM
  3. Printer not installing
    By Lithium in forum Windows
    Replies: 3
    Last Post: 25th February 2008, 03:10 PM
  4. Replies: 3
    Last Post: 13th September 2006, 09:36 AM
  5. printer keeps re installing
    By e_g_r in forum Hardware
    Replies: 4
    Last Post: 6th March 2006, 03:03 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •