home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.pascal
- Path: sparky!uunet!mcsun!news.funet.fi!uwasa.fi!ts
- From: ts@uwasa.fi (Timo Salmi)
- Subject: Re: Getting the prompt from DOS?
- Message-ID: <1992Sep10.055430.3941@uwasa.fi>
- Organization: University of Vaasa, Finland
- References: <1992Sep10.015325.26026@uxa.ecn.bgu.edu>
- Date: Thu, 10 Sep 1992 05:54:30 GMT
- Lines: 18
-
- In article <1992Sep10.015325.26026@uxa.ecn.bgu.edu> mudrc@uxa.ecn.bgu.edu (Daniel R. Crowson) writes:
- > Is there any easy way to retrieve the prompt from dos in TP? I'd like
- > to be able to retrieve it and write it out.
-
- The prompt is stored in an environment variable so you can use the
- GetEnv keyword (see your TP manual if you happen not to be familiar
- with it). But the prompt is given as a code (eg $p$g) so that if
- you wish to read the outcome (eg C:\MYDIR> ) then that is more
- complicated. I can't think at the moment of a way to do it (there
- must be one eg by reading it directly from the screen), but one
- could, of course, interpret the envirinment variables contents. The
- prompt codes are well known.
-
- ..................................................................
- Prof. Timo Salmi
- Moderating at garbo.uwasa.fi anonymous FTP archives 128.214.87.1
- Faculty of Accounting & Industrial Management; University of Vaasa
- Internet: ts@uwasa.fi Bitnet: salmi@finfun ; SF-65101, Finland
-