How to redirect standard error at the same time set UseShellExecute to true?

I have a problem.

Does anyone know mk32 execution?

I am developing a GUI for mk32 cmd execution.
I need to get the standard error of mk32.exe, so I used the following codes:

ProcessObj.StartInfo.UseShellExecute = false;
ProcessObj.StartInfo.RedirectStandardError = true;

It was a success. However, when mk32.exe is compiling correctly, it gets "a dump file error. Win32 error 6". I think it is because of the UseShellExecute property.

How can I get the standard error at the same time set the  UseShellExecute to true?
Thanks for your help.
LVL 10
margajet24IT Business AnalystAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
margajet24Connect With a Mentor IT Business AnalystAuthor Commented:
my groupmate was able to fix this..i dont know yet how he did it

but thanks for the info..
0
 
Bob LearnedConnect With a Mentor Commented:
I don't believe that you can get UseShellExecute and RedirectStandardError to work together.
0
 
Bob LearnedCommented:
It would be interesting to know how this was eventually solved, because I didn't think that it was possible.
0
 
katlin924Commented:
TheLearnedOne,

you're correct. It is not possible to do it. So I just made some adjustments to the code.
I just redirected the standard error manually then read an external file for that.

Thanks for the info.

Btw, I am margajet24's groupmate. =)
0
All Courses

From novice to tech pro — start learning today.