Jump to content

Recommended Posts

Posted

I use WPKG to deploy software and have used this vbs script

Option Explicit
Dim netPrinter, UNCpath
UNCpath = "\\server2\RicohCopier"
Set netPrinter = CreateObject("WScript.Network")
netPrinter.AddWindowsPrinterConnection UNCpath
WScript.Quit

to install printers shared out on my w2k3 servers on XP but they don't work on Win7

 

I beleive this to be because Win7 doesn't have the drivers built in for my photocopiers and of course my w2k3 server knows nothing about win7.

 

I see posts about installing the drivers before installing/mapping the printers but I've no idea how to do this.

 

I don't use domains/GPOs - the w2k3 server is just a file/print server so I'm after a simple script based approach

 

Help! :)

 

Si

Posted

Go to the share and update the drivers to ensure that the drivers installed also support WIndows 7

 

unless you are using 64bit WIndows 7 in which case you need to select the 64 bit drivers for the share

Posted

1 if its x86 win7 the server 03 drivers will probably work if its x64 then just add them to the server

 

2 you may need to play around with point n print settings the settings cant be set from a 2003 server but if you set them using gpmc on a win7 laptop they will apply to other win7 pcs ive found

 

computer config\policies\admin templates\printers\point and print restrictions

 

i set as follows (makes sense if you have the box open) enabled untick,tick do not show, do not show

Posted
As I said

 

:)

 

Si

i assume if it can be done via a gpo there will be a local equivelent but gpp dont show on gpedit.msc so it might be a case of reghacking

Posted

In order to install printers on windows 7 pc's you will need to edit the point and print restrictions on the clients, the easiest way is via a gpo allocated to the machines once this has been done then your vbs will work as expected until then it won't.

 

Ben

Posted

hi Si

 

I use a bat file that works great with windows xp but when I moved to windows 7 I spent hours trying to get the scripts to work and eventually gave up and had to go for gpo because the computers would not install the drivers from the print server. The only problem I have had with the gpo and print management is that you need a windows 2008 r2 server in the domain to set the default printer if you have more than one.

 

Richard

  • Thanks 1
Posted (edited)

You can't install the drivers via script under limited user credentials, can you make it run as a machine startup script which would run it as system?

 

The other thing you can do is edit the local policy or you can push a reg file out with this

 

Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Printers\PointAndPrint]
"Restricted"=dword:00000001
"TrustedServers"=dword:00000000
"ServerList"=""
"InForest"=dword:00000001
"NoWarningNoElevationOnInstall"=dword:00000001
"UpdatePromptSettings"=dword:00000002

http://forums.whirlpool.net.au/archive/1503702

http://social.technet.microsoft.com/Forums/en/w7itpronetworking/thread/ab86bc47-3186-45ec-90e6-a36e7d083deb

 

The reg file would have to be run as a full administrator though so that would need to be run as a machine startup script or by an administrator to apply. After it is applied then the users sould be able to install the drivers off the print server as usual via the script. As above just update the printer drivers to the latest version on the server and under the shareing tab > drivers button you can add the 64 bit drivers if you need them. The drivers 32/64 need the exact same name/version number hence the need to update to the latest versions. Also old drivers are shocking under Vista/7 and will crash the spooler service continuiously.

Edited by SYNACK
  • Thanks 1
Posted

This is for win7 starter netbooks with the user having full admin priviliges and UAC turned off.

 

My 1st problem is that I don't know/can't see how to add Win7 drivers to the w2k3 server :(

 

If I go into the share tab on the server I'm not given the option of Win7 (which doesn't surprise me as w2k3 wouldn't have heard of win 7!)

 

The server was set to auto update but I'm doing a manual one as well in case that helps

 

Si

Posted

If there is no domain in play having re-read it I would think point and print can be configured using the local policies on the machine

 

Ben

Posted

@synack

I've run your script and now my install doesn't hang anymore but the printer hasn't been added as of course neither it or the server have the drivers.

 

Can I get away with just sticking the drivers in a nice easy to find place? :)

 

Si

Posted
've run your script and now my install doesn't hang anymore but the printer hasn't been added as of course neither it or the server have the drivers.

 

Extra info - it just took 4 minutes to come back with a dialog box to tell me that :(

Si

Posted

I've always found con2prt fine with drivers, the only issue has ever been getting a box up to install the driver..

 

from what I've gathered it queries the computer hosting the shared printer and literally, just pulls the driver..

Even worked yesterday sharing a photocopier from server2008 64bit to a win 7 32bit client, just had to add the 32 bit drivers on the server

Posted (edited)

You still need to add the drivers to the server. There is no seporate driver for 7, just a 32 and 64bit windows driver, go to the printer vendor sire and get the latest driver for the latest OS, 2008 r2 or 7 64bit and 7 32 bit and then extract them.

 

Go to the printer in question on the server and go to its properties, go to the advanced tab and click the new driver button, find the extracted driver files and point to them, this will update the driver for the 32bit driver. It will take a while then click ok if the properties box is still up. reopen properties, sharing tab and click the additioal drivers button then tick x64 and point it to the 64bit version.

 

Depending on how bad the drivers are from the vendor you may need to use vista/2008 drivers to support both 2003/xp and 7 as some vendors(brother) could not progra their way out of a paper bag reliably.

 

edit: con2port is just an exe wrapper to the to the same printer apis that are used by most of the other methods, actually the older ones as it is from the windows NT resource kit. VBS, autoit and even direct dll calls are more reliable now as they use the updated APIs rather than the legacy ones.

Edited by SYNACK
  • Thanks 1
Posted
There is no seporate driver for 7, just a 32 and 64bit windows driver, go to the printer vendor sire and get the latest driver for the latest OS, 2008 r2 or 7 64bit and 7 32 bit and then extract them.

 

Go to the printer in question on the server and go to its properties, go to the advanced tab and click the new driver button, find the extracted driver files and point to them, this will update the driver for the 32bit driver. It will take a while then click ok if the properties box is still up. reopen properties, sharing tab and click the additioal drivers button then tick x64 and point it to the 64bit version.

:-)

Thats the bit I hadn't twigged - thanks very much :)

 

Si

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...