Message 1 of 5
How to read current command prompt value

Not applicable
06-25-2003
10:07 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I know this is asked once in a while, but it never seems to be answered in a
satisfactory way (which, of course, could be an answer all in itself). I
need to obtain the string currently being displayed as the command prompt
when AutoCAD is NOT idle (or "quiescent").
I have a batch plotting process that plots drawings dropped in a watched
directory, and it controls AutoCAD via commands sent with SendCommand(). If
the drawing loads fine and there are no problems, the command sequence works
out fine and everything is peachy. If however anything goes wrong, like a
drawing contains fonts that aren't installed and AutoCAD promts the user for
input, this disrupts the whole process. If any given command doesn't
complete normally, with AutoCAD prompting the user for some input, I want to
log this prompt to an error file, kill the session, and move on to the next
drawing.
I can detect whether AutoCAD is not idle after a command by checking
IsQuiescent, but I can't figure out how to obtain the prompt string being
displayed to the user. When AutoCAD is idle, you can use GetVariable() with
"lastprompt" or "cmdnames", but when it's not idle, those won't work. What
other options do I have?
Thanks!
Uwe W. Radu
satisfactory way (which, of course, could be an answer all in itself). I
need to obtain the string currently being displayed as the command prompt
when AutoCAD is NOT idle (or "quiescent").
I have a batch plotting process that plots drawings dropped in a watched
directory, and it controls AutoCAD via commands sent with SendCommand(). If
the drawing loads fine and there are no problems, the command sequence works
out fine and everything is peachy. If however anything goes wrong, like a
drawing contains fonts that aren't installed and AutoCAD promts the user for
input, this disrupts the whole process. If any given command doesn't
complete normally, with AutoCAD prompting the user for some input, I want to
log this prompt to an error file, kill the session, and move on to the next
drawing.
I can detect whether AutoCAD is not idle after a command by checking
IsQuiescent, but I can't figure out how to obtain the prompt string being
displayed to the user. When AutoCAD is idle, you can use GetVariable() with
"lastprompt" or "cmdnames", but when it's not idle, those won't work. What
other options do I have?
Thanks!
Uwe W. Radu