From: Jonathan de Boyne Pollard on
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<blockquote
cite="mid:4fe2e3dc-8a2a-431b-8aa7-d4f4d56dc8c4(a)k13g2000yqe.googlegroups.com"
type="cite">
<blockquote type="cite">
<p>And at this point in the thread we find a problem statement of
another underlying different real problem:</p>
</blockquote>
<p>How is that different from my original post? </p>
</blockquote>
<p>Come now!&nbsp; Surely even you yourself can spot the difference between</p>
<blockquote type="cite">
<p>Now, I am trying to make this into a generic Command Prompt
automation suite, so I can quickly throw together scripts that send
commands to a Command Prompt and interrogate the screen, not limited to
STDIO either, I want this to work with screen-drawing applicatons,
eventually I want to write a Nethack bot with it.</p>
</blockquote>
<p>and</p>
<blockquote type="cite">
<p>Is there any way of getting a handle to the console of a
Command Prompt application?&nbsp; I can get the process ID, because my
Windows program ran the process in the first place, and I have the
window handle. </p>
</blockquote>
<p>and even</p>
<blockquote type="cite">
<p>What I'm actually doing is running a Telnet session,
logging it in, running a couple of commands, then leaving it running.</p>
</blockquote>
<p>.</p>
<blockquote
cite="mid:4fe2e3dc-8a2a-431b-8aa7-d4f4d56dc8c4(a)k13g2000yqe.googlegroups.com"
type="cite">
<p>
<blockquote type="cite">Then you need to read <a
href="http://homepage.ntlworld.com./jonathan.deboynepollard/FGA/capture-console-win32.html">another
Frequently
Given Answer about that</a>.</blockquote>
<br>
There isn't really an answer in there, though, just a general warning
that the approach is problematic.</p>
</blockquote>
<p>That is an answer.&nbsp; That it involves your putting down the
chocolate-covered banana and stepping away from the European currency
systems is the true problem, here.&nbsp; <br>
</p>
</body>
</html>