473,385 Members | 2,003 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Can i send data to my printer through ms-dos based c++ program?

profall
for example to print through LPT1, i can use
<code>FILE*printer;
printer=fopen("LPT1","wb+");
fprintf(printer,"This is message");
</code>
but i want to send it to:USB001
is there a way without going to windows or MFC?
Aug 17 '10 #1
3 2282
weaknessforcats
9,208 Expert Mod 8TB
What are you asking? The code above does not require Windows or MFC.
Aug 17 '10 #2
newb16
687 512MB
I'm not sure that modern printers have teletype mode at all. Taking into account that 'Quite a few parallel port printers don't work in straight ASCII DOS mode either'...
Aug 18 '10 #3
weaknessforcats
9,208 Expert Mod 8TB
The C languaage requires printers to conform to stdout which is a serial teletype. Your printer driver handles this for you. That's why you can print on a 2010 laser printer using a C program written in 1975.

All you have to to is use stdout.
Aug 18 '10 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: sridevi | last post by:
Hello How to export data from ms-access database to excel worksheet using ASP. mainly i need to export data to multiple worksheets. it is very urgent to us. i have a sample code which works...
2
by: Fatih BOY | last post by:
Hi, I want to send a report from a windows application to a web page like 'report.asp' Currently i can send it via post method with a context like local=En&Username=fatih&UserId=45&Firm=none...
4
by: JPO | last post by:
Hi there, I'm trying to use MSAccess as a "container" to move data around from one MS-SQL server DB to another. This is basically already a design decision that has been made for a lot of...
2
by: ads | last post by:
hi i was given a task to display sql server data in ms word using xml. Im currently doing research to accomplish the task. What i have in mind is to create an xml template (or schema?) to load...
0
by: mattc66 via AccessMonster.com | last post by:
Hi All, Is there a way to send data from Access to an Interactive PDF Form? Thanks Matt -- Matt Campbell mattc (at) saunatec com
5
by: trig | last post by:
Please help! I am an ICT teacher at a secondary school and my year 12 (AS Level) group need to create a website where data can be sent from a form to a Microsoft Access database. I am trying...
1
by: krndhi1983 | last post by:
Hi to All, I am using Windows XP running IIS 6.0.I am developing a project using vb.net 1.1 with SQL Server 2000.It is a mobile project.So i am also using Pocket PC 2002 with SQL CE 2.0.When...
1
by: panku007 | last post by:
hi All, I wanted to export excel data into ms word document through java coding.So please send me reply,according to my question. thanks
0
by: realgoggi | last post by:
Hello, I have a label printer connected to LPT1 on the server where IIS and the ASPX/C# code is running. From the web application I need to send data to the printer. Preferably directly,...
5
by: superChaos | last post by:
hi, i'm trying to make macro in ms word.. the idea is ... everytime i push/select save button in ms word, the name and path of current document will automaticly saved to ms access... this far.....
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.