Solved

Printing Data from Files in C / C++

Posted on 2004-09-22
6
143 Views
Last Modified: 2010-04-01
Well I have created 2 files for dmmy project work. I want to print the records which are present in the files as requested by the user.  What command will help me print the record from the file to the printer?
It would be of great help if the help is from C point of view
Thanks
J2
0
Comment
Question by:coolguyj2
[X]
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
  • 2
6 Comments
 
LVL 30

Expert Comment

by:Axter
ID: 12123700
system("copy file.txt prn:");
0
 
LVL 30

Expert Comment

by:Axter
ID: 12123720
The above is a simple method for copying a file to a printer.

But a better answer can be provided if you give us more details of your requirements.

What OS?
What type of printer? (Printer connected to printer port or network printer)
0
 

Author Comment

by:coolguyj2
ID: 12132059
thanx for the reply...
actually, I am reading the file into an array and then will be splittin up array using sscanf()... now these details are displayed on  the screen. I want to print these details on the printer
How can I do it?
I am using Win XP... Printer is n/w printer... dunno all the details...
thanx
J2
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 12687937
PAQed with points refunded (125)

modulo
Community Support Moderator
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

630 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