Send Enter Key to the CONSOLE

  • Thread starter Thread starter ME
  • Start date Start date
M

ME

I can not for the life of me figure out how to send the ENTER key to a
RUNNING instance of the Console. I do not have access to the startup of the
console in this case. I have found a way to attach to the console using
AttachConsole (Kernal32). Now I need to send the Enter key to it. I can
get the cursor to move down one line, but I can not seem to send an Enter so
the command prompt process the command I write.

Can some help? I appear to be stupid.

Thanks,

Matt
 
Hi, I'm not sure what you whant but I think what you meen is the
equivalent to ASCII char #13. Try something like this:

(...)
string myString = "Hello" + Environment.NewLine + "World!";
(...)

It should look like this:

Hello
World

João Carias
(Quina)
 
Hi, I'm not sure what you whant but I think what you meen is the
equivalent to ASCII char #13. Try something like this:

(...)
string myString = "Hello" + Environment.NewLine + "World!";
(...)

It should look like this:

Hello
World

João Carias
(Quina)
 
Back
Top