I have tried to use delphi to send commands to the command prompt.
However, i am not able to do so as i used CreateProcess method to do it.
I have tried to change the StdOutPipeWrite, however, the CreateProcess seems to not allow commands after the initial command from CreateProcess to be passed through.
Is there any way to make use of the handle to continue to send and receive commands and messages to and fro the command prompt and delphi?
I have tried to use delphi to send commands to the command prompt. However,
Share
My fellow member Glenn9999 from tek-tips.com wrote a nice FAQ on this subject.
I don’t know if he’s on SO, but he deserves all the credit for this one.
I copied the code from that page here for future reference. He uses pipes to do the communication between console and delphi.
UPDATE (05/01/2020)
This answer only works on non unicode aware Delphi versions.
You can find a working version here if you have a modern Delphi