Newsgroups: comp.os.msdos.programmer
Path: utzoo!telly!druid!darcy
From: darcy@druid.uucp (D'Arcy J.M. Cain)
Subject: Re: Print String via BIOS and return DOS prompt: How?
Organization: D'Arcy Cain Consulting, West Hill, Ontario
Distribution: na
Date: Sat, 3 Nov 90 13:11:12 GMT
Message-ID: <1990Nov3.131112.17145@druid.uucp>
References: <4741@trantor.harris-atd.com>

In article <4741@trantor.harris-atd.com> Bob Davis writes:
>In a TSR (where, as I understand it, I need to stay out of non-reentrant DOS)
>I want to print a string followed by a return to the DOS prompt.
>
>Using Int 10, Fcn. 0Eh, I get the string OK, but the cursor position is not 
>updated when not at the bottom of the screen, and I do not return to the
>DOS prompt.
>

There isn't really any way to do this.  COMMAND.COM. the program that
prints the prompt, doesn't "know" that it was interrupted and so continues
to wait for a keystroke.  I first thought that you could just shove a
return into the keyboard queue but that doesn't work either.  What if you
have a partial command typed?  You could clear out the input buffer but
you still don't even know that you are in the shell or not.  You may be
in a program where a return could be catastrophic.

What you want to do is re-think how the TSR communicates with the user.
Use a pop-up box or write to some specific location on the screen or
something like that.

-- 
D'Arcy J.M. Cain (darcy@druid)     |
D'Arcy Cain Consulting             |   I support gun control.
West Hill, Ontario, Canada         |   Let's start with the government!
+ 416 281 6094                     |
