WUGNET, the Windows User Group Network
Your Complete Resource Center for "The Best" in Shareware, Computing Tips and Support, Windows Industry News... and much more!
Home Forums Shareware Windows Tips Hot Offers FREE Newsletters Arcade Contact Us About Partners
Search WUGNET: RSS Feeds RSS Feeds Advertise with WUGNET    |    Shareware eBooks
HomeHome FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

Adding a printer/port Commandline - Auto installing printe..

 
Goto page 1, 2
   Home -> Windows -> Print & Fax RSS
Next:  CD drive thinks it's a floppy drive  
Author Message
johnism

External


Since: Sep 17, 2009
Posts: 1



(Msg. 1) Posted: Thu Sep 17, 2009 12:05 pm
Post subject: Adding a printer/port Commandline - Auto installing printers/portd
Archived from groups: microsoft>public>windowsxp>print_fax (more info?)

tried all this
http://forums.techarena.in/xp-print-fax/449346.htm

and here is my command.
Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP PCL
5" -v 3 -e "Windows NT x86" -h "C:\INF" -i "hpcm434b.inf"

error code 87 on the above

Yes drivers are in C:\INF
I have tried
C:\\INF
returns error 87
and
-h "C:\\INF" -i "C:\\INF\\hpcm434b.inf"
returns error -536870353
or
-h "C:\INF" -i "C:\INF\hpcm434b.inf"
returns error -536870353

as far as I can tell the name in the inf is "HP LaserJet M4345 MFP PCL
5"
Below is part of the inf called hpcm434b.inf

[HP]
"HP LaserJet M4345 MFP PCL 5" =
HPCm4345.GPD,USBPRINT\Hewlett-PackardHP_La619B,USBPRINT\VID_03F0&PID_7417&Rev_0100&PRINT_HPZ,DOT4PRT\Hewlett-PackardHP_La619B,DOT4PRT\Hewlett-PackardHP_La619B&PRINT_HPZ,DOT4PRT\Hewlett-PackardHP_La619B&DOT4&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&REV_0100,DOT4PRT\VID_03F0&PID_7417,DOT4PRT\VID_03F0&PID_7417&REV_0100&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&REV_0100&DOT4&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&DOT4&PRINT_HPZ

[HP.NT.6.0]
"HP LaserJet M4345 MFP PCL 5" =
HPCm4345.GPD.NT.6.0,USBPRINT\Hewlett-PackardHP_La619B
"HP LaserJet M4345 MFP PCL 5" =
HPCm4345.GPD.NT.6.0,USBPRINT\VID_03F0&PID_7417&Rev_0100&PRINT_HPZ

"HP LaserJet M4345 MFP PCL 5" =
hpcm4345.GPD.NT.6.0,DOT4PRT\Hewlett-PackardHP_La619B
"HP LaserJet M4345 MFP PCL 5" =
hpcm4345.GPD.NT.6.0,DOT4PRT\Hewlett-PackardHP_La619B&PRINT_HPZ
"HP LaserJet M4345 MFP PCL 5" =
hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417
"HP LaserJet M4345 MFP PCL 5" =
hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417&DOT4&PRINT_HPZ
"HP LaserJet M4345 MFP PCL 5" =
hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417&REV_0100
"HP LaserJet M4345 MFP PCL 5" =
hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417&REV_0100&DOT4&PRINT_HPZ
; OEM URLS
;
; This sections gives the URL for manufacturers found in the
Manufacturers section
[OEM URLS]
%HP% =
"http://go.microsoft.com/fwlink/?LinkID=37&prd=10798&sbp=Printers"


I am at a lost ..thanks for any help ,
John
PS. I do only need the inf located in my "INF" dir and not the cpmplete
HP install dir . I did try that but still no luck.


--
johnism
------------------------------------------------------------------------
johnism's Profile: http://forums.techarena.in/members/136174.htm
View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm

http://forums.techarena.in
Back to top
Login to vote
Alan Morris [MSFT]

External


Since: Oct 25, 2005
Posts: 539



(Msg. 2) Posted: Thu Sep 17, 2009 2:22 pm
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

No need for "" around the path parameter

the help file was updated in Server 2003

Remarks:
The inf file name must be fully qualified. If the inf name is not specified,
the script uses
the ntprint.inf file in the inf subdirectory of the Windows directory.
If the driver path is not specified, the script searches for driver files in
the driver.cab file.



that said you still will not get the driver installed until you locate the
correct language cab and extract the files to the c:\inf directory or you
will get error 2 file not found. I have the PCL 6 and it's a different
version so the file names are different but look for the one with en in the
name if you need English. The PCL 6 version is p6i2enww.cab.

Thanks to Eric Michaud for figuring this HP issue out 3 years ago. He was
using German which is the de version of the file.


C:\INF>Cscript %WINDIR%\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP
PCL 6" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434c.inf
Microsoft (R) Windows Script Host Version 5.6
Copyright (C) Microsoft Corporation 1996-2001. All rights reserved.

Unable to add printer driver HP LaserJet M4345 MFP PCL 6 Win32 error code 2


after extracting the English files

C:\INF>Cscript %WINDIR%\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP
PCL 6" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434c.inf
Microsoft (R) Windows Script Host Version 5.6
Copyright (C) Microsoft Corporation 1996-2001. All rights reserved.

Added printer driver HP LaserJet M4345 MFP PCL 6


--
Alan Morris
Windows Printing Team
Search the Microsoft Knowledge Base here:
http://support.microsoft.com/search/?adv=1

This posting is provided "AS IS" with no warranties, and confers no rights.

"johnism" <johnism.3ynybb DeleteThis @DoNotSpam.com> wrote in message
news:johnism.3ynybb@DoNotSpam.com...
>
> tried all this
> http://forums.techarena.in/xp-print-fax/449346.htm
>
> and here is my command.
> Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP PCL
> 5" -v 3 -e "Windows NT x86" -h "C:\INF" -i "hpcm434b.inf"

this is wrong -i should be c:\inf\hpcm434b.inf
>
> error code 87 on the above
>
> Yes drivers are in C:\INF
> I have tried
> C:\\INF
> returns error 87
> and
> -h "C:\\INF" -i "C:\\INF\\hpcm434b.inf"
this is wrong no need to escape the \

> returns error -536870353
> or
> -h "C:\INF" -i "C:\INF\hpcm434b.inf"
> returns error -536870353

this should result in file not found error 2

>
> as far as I can tell the name in the inf is "HP LaserJet M4345 MFP PCL
> 5"
> Below is part of the inf called hpcm434b.inf
>
> [HP]
> "HP LaserJet M4345 MFP PCL 5" =
> HPCm4345.GPD,USBPRINT\Hewlett-PackardHP_La619B,USBPRINT\VID_03F0&PID_7417&Rev_0100&PRINT_HPZ,DOT4PRT\Hewlett-PackardHP_La619B,DOT4PRT\Hewlett-PackardHP_La619B&PRINT_HPZ,DOT4PRT\Hewlett-PackardHP_La619B&DOT4&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&REV_0100,DOT4PRT\VID_03F0&PID_7417,DOT4PRT\VID_03F0&PID_7417&REV_0100&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&REV_0100&DOT4&PRINT_HPZ,DOT4PRT\VID_03F0&PID_7417&DOT4&PRINT_HPZ
>
> [HP.NT.6.0]
> "HP LaserJet M4345 MFP PCL 5" =
> HPCm4345.GPD.NT.6.0,USBPRINT\Hewlett-PackardHP_La619B
> "HP LaserJet M4345 MFP PCL 5" =
> HPCm4345.GPD.NT.6.0,USBPRINT\VID_03F0&PID_7417&Rev_0100&PRINT_HPZ
>
> "HP LaserJet M4345 MFP PCL 5" =
> hpcm4345.GPD.NT.6.0,DOT4PRT\Hewlett-PackardHP_La619B
> "HP LaserJet M4345 MFP PCL 5" =
> hpcm4345.GPD.NT.6.0,DOT4PRT\Hewlett-PackardHP_La619B&PRINT_HPZ
> "HP LaserJet M4345 MFP PCL 5" =
> hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417
> "HP LaserJet M4345 MFP PCL 5" =
> hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417&DOT4&PRINT_HPZ
> "HP LaserJet M4345 MFP PCL 5" =
> hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417&REV_0100
> "HP LaserJet M4345 MFP PCL 5" =
> hpcm4345.GPD.NT.6.0,DOT4PRT\VID_03F0&PID_7417&REV_0100&DOT4&PRINT_HPZ
> ; OEM URLS
> ;
> ; This sections gives the URL for manufacturers found in the
> Manufacturers section
> [OEM URLS]
> %HP% =
> "http://go.microsoft.com/fwlink/?LinkID=37&prd=10798&sbp=Printers"
>
>
> I am at a lost ..thanks for any help ,
> John
> PS. I do only need the inf located in my "INF" dir and not the cpmplete
> HP install dir . I did try that but still no luck.
>
>
> --
> johnism
> ------------------------------------------------------------------------
> johnism's Profile: http://forums.techarena.in/members/136174.htm
> View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm
>
> http://forums.techarena.in
>
Back to top
Login to vote
johnism

External


Since: Sep 18, 2009
Posts: 1



(Msg. 3) Posted: Thu Sep 17, 2009 6:05 pm
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

so needless to say I am having no luck in figuring out what is failing.
Thanks for any help,
John


--
johnism
------------------------------------------------------------------------
johnism's Profile: http://forums.techarena.in/members/136174.htm
View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm

http://forums.techarena.in
Back to top
Login to vote
johnism

External


Since: Sep 18, 2009
Posts: 1



(Msg. 4) Posted: Fri Sep 18, 2009 1:05 pm
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

so I found p5i2enww.cab and extraced
(unidrvui.dll,unires.dll,unidrv.hlp) and placed them in C:\INF.

with this
Cscript %WINDIR%\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP
PCL 5" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434b.inf

returned error -536870353

then I tried this

Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP
PCL 5" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434b.inf

returned error -536870353

I forg to to mention that the person who builds our XP image changed it
too WINNT for legacy aps.

this works like a champ for adding the port
Cscript C:\WINNT\System32\Prnport.vbs -a -r IP_1 -h 165.245.192.245 -o
raw


Thanks again for any help,
John


--
johnism
------------------------------------------------------------------------
johnism's Profile: http://forums.techarena.in/members/136174.htm
View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm

http://forums.techarena.in
Back to top
Login to vote
Alan Morris [MSFT]

External


Since: Oct 25, 2005
Posts: 539



(Msg. 5) Posted: Fri Sep 18, 2009 2:33 pm
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

I'll assume there have not been any changes to the inf file that would
break the digital signature. Verify that the print driver can be installed
without any signature warning and that the add driver wizard states the
driver is signed when using the UI (be sure to enable the signature warnings
if you disabled them). WMI cannot be used to install unsigned drivers. If
you installed .NET 3.5 SP1 there was a unidrv file that caused any other
drivers to throw a warning and this will also affect the ability to install
drivers using WMI.

There is a download to add the signature to the machine.

--
Alan Morris
Windows Printing Team
Search the Microsoft Knowledge Base here:
http://support.microsoft.com/search/?adv=1

This posting is provided "AS IS" with no warranties, and confers no rights.

"johnism" <johnism.3ypvrc.RemoveThis@DoNotSpam.com> wrote in message
news:johnism.3ypvrc@DoNotSpam.com...
>
> so I found p5i2enww.cab and extraced
> (unidrvui.dll,unires.dll,unidrv.hlp) and placed them in C:\INF.
>
> with this
> Cscript %WINDIR%\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP
> PCL 5" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434b.inf
>
> returned error -536870353
>
> then I tried this
>
> Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP
> PCL 5" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434b.inf
>
> returned error -536870353
>
> I forg to to mention that the person who builds our XP image changed it
> too WINNT for legacy aps.
>
> this works like a champ for adding the port
> Cscript C:\WINNT\System32\Prnport.vbs -a -r IP_1 -h 165.245.192.245 -o
> raw
>
>
> Thanks again for any help,
> John
>
>
> --
> johnism
> ------------------------------------------------------------------------
> johnism's Profile: http://forums.techarena.in/members/136174.htm
> View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm
>
> http://forums.techarena.in
>
Back to top
Login to vote
johnism

External


Since: Sep 22, 2009
Posts: 1



(Msg. 6) Posted: Tue Sep 22, 2009 11:05 am
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

I can manually install the driver with the GUI by pointing to it with
the "have a disk Option " and it listed it as digitally assigned and
installed it fine. Now I did need to add some files but then it
installed ok and printed. I then add those files I need to the INF dir
and tried

Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP PCL
5" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434b.inf

returned erorr code -536870353

Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP PCL
5" -v 3 -e "Windows NT x86" -h C:\INF -i hpcm434b.inf

returned error code 87

Thanks again,
John


--
johnism
------------------------------------------------------------------------
johnism's Profile: http://forums.techarena.in/members/136174.htm
View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm

http://forums.techarena.in
Back to top
Login to vote
Alan Morris [MSFT]

External


Since: Oct 25, 2005
Posts: 539



(Msg. 7) Posted: Tue Sep 22, 2009 3:25 pm
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

did you try the PCL 6 version of the driver or download the most recent PCL
5 version?

your second example with error 87 is expected since you are passing in
invalid information in the -i parameter.

--
Alan Morris
Windows Printing Team
Search the Microsoft Knowledge Base here:
http://support.microsoft.com/search/?adv=1

This posting is provided "AS IS" with no warranties, and confers no rights.

"johnism" <johnism.3yx4vb DeleteThis @DoNotSpam.com> wrote in message
news:johnism.3yx4vb@DoNotSpam.com...
>
> I can manually install the driver with the GUI by pointing to it with
> the "have a disk Option " and it listed it as digitally assigned and
> installed it fine. Now I did need to add some files but then it
> installed ok and printed. I then add those files I need to the INF dir
> and tried
>
> Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP PCL
> 5" -v 3 -e "Windows NT x86" -h C:\INF -i C:\INF\hpcm434b.inf
>
> returned erorr code -536870353
>
> Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet M4345 MFP PCL
> 5" -v 3 -e "Windows NT x86" -h C:\INF -i hpcm434b.inf
>
> returned error code 87
>
> Thanks again,
> John
>
>
> --
> johnism
> ------------------------------------------------------------------------
> johnism's Profile: http://forums.techarena.in/members/136174.htm
> View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm
>
> http://forums.techarena.in
>
Back to top
Login to vote
johnism

External


Since: Sep 23, 2009
Posts: 1



(Msg. 8) Posted: Wed Sep 23, 2009 11:05 am
Post subject: Re: Adding a printer/port Commandline - Auto installing printers/portd [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

tried pcl 6
Cscript C:\WINNT\System32\prndrvr.vbs -a -m "HP LaserJet 4345 mfp PCL
6" -v 3 -e "Windows NT x86" -h C:\INF\HP4345PCL6 -i
C:\INF\HP4345PCL6\hpc4345c.inf

returned error code 2


--
johnism
------------------------------------------------------------------------
johnism's Profile: http://forums.techarena.in/members/136174.htm
View this thread: http://forums.techarena.in/xp-print-fax/1247812.htm

http://forums.techarena.in
Back to top
Login to vote
Display posts from previous:   
       Home -> Windows -> Print & Fax All times are: Eastern Time (US & Canada) (change)
Goto page 1, 2
Page 1 of 2

 
You can post new topics in this forum
You can reply to topics in this forum
You can edit your posts in this forum
You can delete your posts in this forum
You can vote in polls in this forum
Categories:
  Windows XP
 Windows Vista
 Windows Other
 Office
 Office Other
 Security
  • Home |
  • Shareware |
  • Windows Tips |
  • Hot Offers |
  • FREE Newsletters |
  • Arcade |
  • Forums |
  • eBooks |
  • About WUGNET |
  • Partners |
  • Contact

  • WUGNET Privacy Policy |
  • Link to WUGNET |
  • IT Support