amset

.info
.co.uk - exchange consultancy
.net - internet based solutions

Broadband - Exchange
Login Scripts - Net Admin
Outlook - Windows Mobile
Windows

Contact - Advertise

AddThis Social Bookmark Button

Login Scripts

Getting Started

Creating the Initial File

Testing

Implementation

Basic Techniques

Mapping Network Drives

Connecting Printers

Section Labels

More Advanced
Techniques

Domain Group Membership For Drive and Printer Mapping 

Recording Script Results

Location Detection

Machine Identification

Operating System Detection

Limiting the Number of Logins

Registry Changes

Redirection of Internet Explorer Favourites

Checking for Existence
of a File or Directory

Working with Printers

If you have networked printers, then you probably have them shared from one of your servers. You can also use a login script to connect your users to these. This makes managing printers across a network very easy as users will be connected to the printers each time they login - even if they haven't used that machine before.

Connecting to Printers

There are two ways of connecting to printers.

DOS Command Utility

To make the connection to the printers via a login script requires a small resource kit utility to "con2prt.exe". This can also be found in the NT 4.0 Zero Administration Kit which you can download from here
You don't have to use the rest of the ZAK to get this utility and this utility works on Windows 2000 and higher as well as NT 4.0. 

To use, simply enter the command along with the switch /c to indicate that you actually want to connect to it along with the path to the printer.
For example to connect to a printer shared as hp-printer on server1 you would enter:

con2prt /c \\server1\hp-printer

If you wanted this printer to be the default printer, then you would change the switch to /cd instead:

con2prt /cd \\server1\hp-printer

If you have multiple printers you should play around with the order they appear in the script so that the most common used is at the end.

Using the Built in Mechanism

If you don't want to use another file to make the connection, you can also use the built in mechanism. The drawback with this method is that it only works on Windows 2000 or higher. To connect to the printer using the names above would mean the following command:

rundll32 printui.dll,PrintUIEntry /in /n \\server1\hp-printer

Disconnecting Printers

You can also use con2prt to disconnect network printers, although the command deletes all network connected printers. This is done with the command:

con2prt /f

If you are using the script to connect network printers, you might want to put this command at the top, so that the user account is reconnected to the printer each time. Any changes made to the central printer will then be passed across to the client machines at the next login.

Sponsored Links

Last Page Update:
30/04/2006

Back to the Top
Contact Us - Advertise on amset.info
Login Scripts Index - Home Page


Broadband - Exchange - Login Scripts - Network Admin - Outlook - Windows Mobile - Windows


© Amset IT Solutions Ltd. 1998 - 2008. All rights reserved. Reproduction of any content on this web site is prohibited without express written consent. Use of this web site is subject to our terms and conditions. All trademarks and registered trademarks are property of their respective owners. This site is not endorsed or recommended by any company or organisation mentioned on this site. This site is to provide guidance only and as such we cannot be held responsible for any consequences of following the advice given.