How to capture the standard output/error of a Process?

前端 未结 3 1954
青春惊慌失措
青春惊慌失措 2021-01-20 01:46

How does one capture the standard output/error of a process started by a Process.Start() to a string?

3条回答
  •  梦毁少年i
    2021-01-20 02:23

    To solve the deadlock problems use this approach:

    ProcessStartInfo hanging on "WaitForExit"? Why?

    Works well in my code...

提交回复
热议问题