Process redirectStandardOutput into a textBox?

  • Thread starter Thread starter Ole
  • Start date Start date
You could put the output into a property in a class, and bind *that* to a
textbox. That's one idea.

Robin S.
 
You cant bind a stream to a textbox but there is an event on the Process
object that fires when texts is written to the output stream. You can handle
this event and use textbox.Invoke to update the textbox text. You have to use
invoke as the event fires on a background thread.
 
Thanks,

I've now tried to use the event from the output stream, but it seems like
the process doesn't output anything until it has finished. Under normal
conditions the commandline program outputs some information every 3'rd
second, but as written I only got the event when the command line program
exits??? Is that a normal behaviour from a DOS program?

Thanks,
Ole
 
Back
Top