Path: utzoo!dciem!nrcaer!scs!spl1!laidbak!att!pacbell!ames!ll-xn!husc6!cs.utexas.edu!ut-sally!ut-emx!boerner From: boerner@ut-emx.UUCP (Brendan B. Boerner) Newsgroups: comp.sys.ibm.pc Subject: Re: C write() operations to MS-DOS devices? Message-ID: <2979@ut-emx.UUCP> Date: 2 Jun 88 20:22:10 GMT Article-I.D.: ut-emx.2979 References: <1318@tahoe.unr.edu> Reply-To: boerner@emx.UUCP (Brendan B. Boerner) Organization: Univ. of Texas at Austin, Computation Center Lines: 22 In article <1318@tahoe.unr.edu> malc@tahoe.unr.edu (Malcolm L. Carlock) writes: > >Can anyone tell me, or point me to some info describing, how to do a C write() >operation to an MS-DOS device (such as PRN, AUX, etc.) ? > >I have looked through the MicroSoft C V.5.0 manuals, but have found very >little, if anything, on this subject. The DOS manual likewise had little >or nothing to say about these devices, programming-wise. > >Neither PRN nor LPT1 are defined in any of the I/O or file-control .h files, >nor do they appear in any of the C manual indexes. > >Thanks in advance, I don't know about PRN: or LPTx:, but I tried to access COM0x: as files using MS QuickC and found that I could not get it to work. MS tech support told me that I would need to write some code to read/write to the serial ports as you couldn't open them as files. Hope this helps. Brendan