interactive shell code lazarus / 11-Options ---------------------------------------------------------------------- endik · 2007-04-23 21:54 Hi advsers, I am trying to make an interface for my shell codes to make my life easier. Now I got stuck since have problems with interactive code. When I call my code: proces.CommandLine:='mycode'; proces.Options:=proces.Options+[poWaitOnExit]; proces.Execute; mycode is started running but stopped after a while since is waiting for commands.  When calling it form the shell I can prepare a file with answers for mycode questions and type: my code < answerfile Unfortunately it does not work when called from lazarus (under llinuks). If someone can help please write an example solution Thanks in advance ---------------------------------------------------------------------- antonio · 2007-04-27 04:43 Is it a console application? ---------------------------------------------------------------------- endik · 2007-04-27 05:42 that's right ---------------------------------------------------------------------- antonio · 2007-04-27 11:55 Perhaps it could be better if you try free pascal forums, http://community.freepascal.org:10000/bboards/ . I think you could have a better answer there. ---------------------------------------------------------------------- endik · 2007-04-27 12:02 ok, thanks Antotnio, I will check and back to you if neccessary ---------------------------------------------------------------------- antonio · 2007-04-27 12:32 I found this link there, http://community.freepascal.org:10000/bboards /message?message_id=236010&forum_id=24083 I hope it can help you. ---------------------------------------------------------------------- Vincent Snijders · 2007-04-27 13:26 Take a look at the processdemo example mentioned at http://wiki.lazaru s.freepascal.org/Executing_External_Programs#Using_input_and_output_of _a_TProcess