Annoyances.org
Home » Windows XP Discussion Forum » Message 1211191192 Search | Help | Home
  
Tip: Run a free scan for common Windows errors ad

re: Command Line Print Command - Help Mapping a Networked Printer to LPT1
Monday, May 19, 2008 at 2:59 am
Windows XP Annoyances Discussion Forum
Posted by normanw (868 messages posted)


You should have posted this in the original thread opened by the
person who asked for the information.






On Saturday, May 17, 2008 at 5:29 pm, Moon Raker wrote:
>1.) Download the kix32.com
> kixtart scripting command
>
>http://www.kixtart.org/downloads/
>
>3.) Copy and Paste the following into notepad save as
> print.bat
>
> $Printer =
>
>READVALUE("HKEY_CURRENT_USER\Software\Microsoft\Windows
>
>NT\CurrentVersion\Windows","Device");
>
> $Index = 1
>
> WHILE $Index < LEN($Printer)
>
> $Testchar = SUBSTR($Printer, $Index, 1)
> IF $Testchar = ','
> $Cutat = $Index - 1
> $Index = LEN($Printer)
> ENDIF
>
> $Index = $Index + 1
>
> LOOP
>
> $Printer = SUBSTR($Printer, 1, $Cutat)
> $Checklocal = SUBSTR($Printer, 1, 2)
>
> ? "Default Printer: $Printer"
>
> ; only map if Default Printer is Network Printer
> IF $Checklocal = "\\"
> ? "Removing existing LPT1 mapping ..."
> USE LPT1 /D
> USE LPT1 $Printer
> IF @ERROR
> BEEP
> ? "Error @ERROR mapping
>
>$Printer to LPT1"
> ELSE
> ? "Done. $Printer mapped to
>
>LPT1"
> ENDIF
> ELSE
> ? "ABORT. Default Printer is not a network
>
>printer!"
> ENDIF
>
>
>4.) run the command
>kix32.exe print.bat
>
>This will look for a networked printer and map it to LPT1.
>Now you can use the dos command print.
>
>example:
>print print.bat or print filename



Written in response to:
Command Line Print Command - Help Mapping a Networked Printer to LPT1 (Moon Raker: Saturday, May 17, 2008 at 5:29 pm)

There are presently no replies to this message.

All messages in this thread [show all]
-Command Line Print Command - Help Mapping a Networked Printer to LPT1 (Moon Raker: Sat, May 17, 2008, 5:29 pm)
*re: Command Line Print Command - Help Mapping a Networked Printer to LPT1 (normanw: Mon, May 19, 2008, 2:59 am)
Return to the Windows XP Discussion Forum


All content at Annoyances.org is Copyright © 1995-2008 Creative Elementtm All rights reserved.
Please do not plagiarize; redistributing these pages without permission is strictly prohibited.