Mail Archives: djgpp/1999/02/16/16:07:15

Message-ID: <>
From: David Nugent <davidn AT cbhc DOT ns DOT ca>
X-Mailer: Mozilla 3.01 (WinNT; I)
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Help with sending a file to a printer.
References: <36C95237 DOT C81A112D AT cbhc DOT ns DOT ca> <199902161746 DOT MAA04793 AT envy DOT delorie DOT com>
Lines: 17
Date: Tue, 16 Feb 1999 14:49:34 +0000
X-Trace: 919198192 (Tue, 16 Feb 1999 16:49:52 ADT)
NNTP-Posting-Date: Tue, 16 Feb 1999 16:49:52 ADT
Organization: Business Internet
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

DJ Delorie wrote:
> > in=fopen("TEST.PRN","rb");
> > while((c=fgetc(in))!=EOF)  fputc(c,stdprn);
> Try adding this before that while loop:
>         setmode(fileno(stdprn), O_BINARY);
> You'll need #include <fcntl.h> also.

Thank you very much!  I tried this suggestion and it
fixed my problem.

Greatly appreciated!
Dave Nugent

- Raw text -

  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019