How to send a file to a specified LPT device using Visual C++ 6.0.
Tufail
Printable View
How to send a file to a specified LPT device using Visual C++ 6.0.
Tufail
The idea:
char lpBuf[80]="just test";
int u=_open(_T("LPT1"),_O_BINARY | _O_RDWR);
write(u,lpBuf,80);
_close(u);
Dmitriy, MCSE
Sir,
What I want is this
We have a dos command like this
type a.txt > LPT1
I want to do the same but by some other means so that the program doesn't have to enter the DOS prompt
Try the example. If you want to send file, just replace lpBuf in _write() with pointer to buffer where you have loaded in memory file.
Did I missunderstand something?
Dmitriy, MCSE