Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!elroy.jpl.nasa.gov!sdd.hp.com!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!att!emory!gatech!uflorida!reef.cis.ufl.edu!jdb From: jdb@reef.cis.ufl.edu (Brian K. W. Hook) Newsgroups: comp.os.msdos.programmer Subject: Using DOS INT21 to read from a file Message-ID: <26647@uflorida.cis.ufl.EDU> Date: 3 Feb 91 19:12:05 GMT Sender: news@uflorida.cis.ufl.EDU Organization: UF CIS Dept. Lines: 23 I am using TASM and TC++ to try and read from a file in section of code of mine. I am using inline assembly.... char c[2]; asm { mov ah, 3FH mov bx, fhandle mov cx, 0001H mov dx, c int 21 } Now fhandle is 0 for stdin, I am just trying to read a single character. I want to use the DOS INT instead of read or fread since I want my code as small as possible. AX returns 86C0, which is REALLY wrong. AX should be the number of bytes read or at least an error code....what am I doing wrong? Thanks, Brian