Ryan233 Posted May 18, 2012 Posted May 18, 2012 (edited) Good Afternoon I have used vb scripts for everyjob i have done in schools and in the nhs, i came to this school and now im having so much issues with vb scripts. This is the script i'm using Set WshNetwork = CreateObject("WScript.Network") PrinterPath = "\\SERVERNAME\Sharp_MXM450N" PrinterDriver = "Sharp_MXM450N" WshNetwork.AddWindowsPrinterConnection PrinterPath, PrinterDriver WshNetwork.SetDefaultPrinter "\\SERVERNAME\Sharp_MXM450N" this has worked for all printer in the school except HP prints. Im so confused why it will not work with HP printings. This is the error i got Can anyone help me out here! Thank you Ryan Edited May 18, 2012 by Ryan233
Ryan233 Posted May 18, 2012 Author Posted May 18, 2012 The printer drivers are installed. i have tried to uninstall and then reinstall them but its still not working
Mcshammer_dj Posted May 18, 2012 Posted May 18, 2012 is this 64bit 32 bit issue?? If you are using a 64bit server have you installed the 32 bit drivers for clients
Ryan233 Posted May 18, 2012 Author Posted May 18, 2012 This is a 32 bit issue We are using 32 bit server and 32 bit cilents
cromertech Posted May 18, 2012 Posted May 18, 2012 I discovered in the past that the HP printer drivers are very picky about the names. Take alook in the inf file to see what the driver is actually being called or try the HP universal driver if it will support the printers you have. I had a hell of a job with the HP printers and once I got it working I didn't ever try an update of the driver just in case it broke it all again ;-)
Mcshammer_dj Posted May 18, 2012 Posted May 18, 2012 what type of HP printer are you having the problem with??
Ryan233 Posted May 18, 2012 Author Posted May 18, 2012 I discovered in the past that the HP printer drivers are very picky about the names. Take alook in the inf file to see what the driver is actually being called or try the HP universal driver if it will support the printers you have. I had a hell of a job with the HP printers and once I got it working I didn't ever try an update of the driver just in case it broke it all again ;-) I will have a look at this nd get back to you
plexer Posted May 18, 2012 Posted May 18, 2012 Don't bother with specifying the driver just use: WNet.AddWindowsPrinterConnection PrinterPath Ben 1
mac_shinobi Posted May 18, 2012 Posted May 18, 2012 Don't bother with specifying the driver just use: WNet.AddWindowsPrinterConnection PrinterPath Ben That's what I was going to say 1
plexer Posted May 18, 2012 Posted May 18, 2012 It'll then install the driver associated with the shared printer. Ben 1
mac_shinobi Posted May 18, 2012 Posted May 18, 2012 It'll then install the driver associated with the shared printer. Ben Bazinga !!
Ryan233 Posted May 21, 2012 Author Posted May 21, 2012 Well i tried using the suggests above and none of them worked for the HP Printers i tried using WNet.AddWindowsPrinterConnection PrinterPath instead and believe it or not it came up with the following error I have tried installing different drivers and universal drivers, with no luck
sted Posted May 21, 2012 Posted May 21, 2012 ive never had to specify the driver for a printer before i just use the following ' suiteprinters.vbs - Jonathan Option Explicit Dim objNetwork on error resume next Set objNetwork = CreateObject("WScript.Network") objNetwork.AddWindowsPrinterConnection "\\server\libbw01" objNetwork.SetDefaultPrinter "\\server\libbw01" i have found though that if your share name and printer naem are eifferent it can cause some issues on win7 (so printer is shared as say \\server\printer1 but its named suite1 printer)
Ryan233 Posted May 21, 2012 Author Posted May 21, 2012 (edited) Well we have three HP printers. The main ones are a HP2550n and im using the HP universal Printing driver. Now When i have just tried to connect to this printer is saying it cannot find the correctly driver so it looks like its something to with the driver installed. PS i have just tried to installed the HP laserjet 2550n pcl6 driver but i still get the same thing Any help would be greatly appreciated Edited May 21, 2012 by Ryan233
caffrey Posted May 21, 2012 Posted May 21, 2012 Sure you're specifying the correct driver (as found in the test page) ? eg PrinterDriver = "HPZ2KU09.DLL" for instance
Ryan233 Posted May 21, 2012 Author Posted May 21, 2012 Sure you're specifying the correct driver (as found in the test page) ? eg PrinterDriver = "HPZ2KU09.DLL" for instance Yeah i tried the following Drivername = UNIDRV.DLL and ICTcolour. None of these has worked
Mcshammer_dj Posted May 21, 2012 Posted May 21, 2012 so to confirm, you have a number of printers you give them an IP address and installed them on the server and then share on the server giving them a unique name each. what happens if you simply go to the \\servername and then double click on the printer to install it??
Ryan233 Posted May 21, 2012 Author Posted May 21, 2012 so to confirm, you have a number of printers you give them an IP address and installed them on the server and then share on the server giving them a unique name each. what happens if you simply go to the \\servername and then double click on the printer to install it?? Like i mentioned above it tries to connect to the windows update to download a driver. it comes back with no driver recognized Then it basically says you can manually select a drivers INF file or cancel. I think this is the issue but i have tried three different drivers now and none of them work. btw if i try to manually attach the pcl6 driver to this printer it comes with another error saying Windows cannot connect to the printer but users can browse the network find the printer an print.
Mcshammer_dj Posted May 21, 2012 Posted May 21, 2012 have you checked the share levels on the srever and who is able to get to the shared driver on the server
Ryan233 Posted May 21, 2012 Author Posted May 21, 2012 (edited) have you checked the share levels on the srever and who is able to get to the shared driver on the server I have just looked at this and there seems to be fine with permissions. This issue is starting to really annoy me haha I have just tried to connect to all the HP printers and all of them search for the driver Edited May 21, 2012 by Ryan233
Mcshammer_dj Posted May 21, 2012 Posted May 21, 2012 Is the printer installed on the server and does it print etc as expected?
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now