Article View: comp.sys.ibm.pc
Article #26240Re: Bat file using ESC seq needs to find if DEVICE=ANSI.SYS was set
From: William E. Davidsen Jr
Date: Thu, 07 Apr 1988 18:19
Date: Thu, 07 Apr 1988 18:19
13 lines
1063 bytes
1063 bytes
From the DOS3.00 tech ref manual, pg 2-10:
If you send the console device a "Device Ststus Report" escape
sequence, which is ESC[6n it will return a "Cursor Position Report"
which is ESC[#;#R. The first # is line, the second column. Don't know if
they're 0 or 1 based.
Just remember to do a non-blocking read (raw read) when checking for
the return value, as you'll hang waiting for keyboard input otherwise.
--
bill davidsen (wedu@ge-crd.arpa)
{uunet | philabs | seismo}!steinmetz!crdos1!davidsen
"Stupidity, like virtue, is its own reward" -me
Technical Details
Message-ID:
<10311@steinmetz.ge.com>Path:
arc1-ca.pugleaf.net!utzoo!mnetor!uunet!steinmetz!davidsenReferences:
<767@ms3.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!steinmetz!davidsen From: davidsen@steinmetz.ge.com (William E. Davidsen Jr) Newsgroups: comp.sys.ibm.pc Subject: Re: Bat file using ESC seq needs to find if DEVICE=ANSI.SYS was set Message-ID: <10311@steinmetz.ge.com> Date: 7 Apr 88 18:19:38 GMT References: <767@ms3.UUCP> Reply-To: davidsen@crdos1.UUCP (bill davidsen) Organization: General Electric CRD, Schenectady, NY Lines: 13 Keywords: ansi.sys, Escape Sequences, errorlevel, find, grep, DOS, unix