From: Nate Eldredge Newsgroups: comp.os.msdos.djgpp Subject: Re: fprintf to HP Deskjet Date: 29 Nov 1999 16:13:36 -0800 Organization: InterWorld Communications Lines: 26 Message-ID: <83so1ohm4v.fsf@mercury.st.hmc.edu> References: <81uq89$n0l$1 AT news2 DOT tor DOT accglobal DOT net> NNTP-Posting-Host: mercury.st.hmc.edu X-Trace: nntp1.interworld.net 943920884 10975 134.173.45.219 (30 Nov 1999 00:14:44 GMT) X-Complaints-To: usenet AT nntp1 DOT interworld DOT net NNTP-Posting-Date: 30 Nov 1999 00:14:44 GMT X-Newsreader: Gnus v5.7/Emacs 20.4 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com "Michel Chassey" writes: > Hello everyone, > I invoke gcc : gcc -o f.exe f.c (for testing) > Here is the f.c listing : > #include > int main( void ) > { > fprintf ( stdprn, "Hello World" ); > return( 1 ); > } > The printer goes though the motion of printing then hangs. Lights blink but > no printing: > result blank page. Most printers need a form-feed sent to cause them to actually print the page (until then, they just buffer it). Try adding a "\f" character to the string. Incidentally, it's traditional for `main' to return 0 on "success", and it appears your program should normally be successful. -- Nate Eldredge neldredge AT hmc DOT edu