Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How to print from the command line to USB printer?

Posted on 2004-08-03
7
1,940 Views
Last Modified: 2008-02-01
I run win xp and i want to print files from the command line to my USB printer.
I wrote this int the CMD:
print /d:USB001 C:\111.txt
but then i get the message:
unable to initialize device USB001
Is that possible?
0
Comment
Question by:omer_667721
  • 4
  • 3
7 Comments
 
LVL 32

Accepted Solution

by:
LucF earned 50 total points
ID: 11704909
Hi omer_667721,

Share the printer on the network, then use the following command:

Net use lpt1: \\localhost\<printersharename> /PERSISTENT:YES

Now you can print from dos using the normal lpt1: port :)

Greetings,

LucF
0
 

Author Comment

by:omer_667721
ID: 11705563
Is it possible to print also files like HTML or DOC in that way?
0
 
LVL 32

Expert Comment

by:LucF
ID: 11705590
Never tried it, but I can't see why not...
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:omer_667721
ID: 11705841
I just tried to print a DOC file and i got gibrish...
when i tried to print HTML file i fot only the source code of the HTML
0
 
LVL 32

Expert Comment

by:LucF
ID: 11705875
For the html, that's normal, and for the DOC, if it's not plain text, it's also to be expected.
0
 

Author Comment

by:omer_667721
ID: 11706214
OK
thanks
0
 
LVL 32

Expert Comment

by:LucF
ID: 11706249
You're welcome :)

LucF
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you use a Brother DCP 130C or similar Brother printer, at some point you might encounter the following problem: after you change the ink cartridge, the printer displays an "ink empty" message. Sometimes you just need to follow the instructions…
How to solve seemingly unsolvable printer issues. Users sometimes run into printing issues where all the normal steps do not seem to work. Well the steps below can show users how to take one extra step beyond the normal steps needed to remove old…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question