Solved

How to print from the command line to USB printer?

Posted on 2004-08-03
7
1,837 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:
Luc Franken 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:Luc Franken
ID: 11705590
Never tried it, but I can't see why not...
0
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 

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:Luc Franken
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:Luc Franken
ID: 11706249
You're welcome :)

LucF
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

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…
Printers have changed substantially in the last 30 or so years, not just in technical capabilities but in cost and usage as well.  Printers were originally used for interfacing with the operator, not necessarily for printing copy or pictures. In …
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

708 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

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now