Hi. I am using a ProcessStartInfo to patch a file with a text file like this (through cmd.exe):
app.exe temp.txt patch.ips
I wrote this code:
ProcessStartInfo P = new ProcessStartInfo("app.exe");
P.Arguments = "temp.txt " + _patchpath;
P.CreateNoWindow = true;
P.UseShellExecute = false;
P.RedirectStandardOutput = true;
Process.Start(P);
app.exe and temp.txt are relative to my application path (note: app.exe isn't the name of my C# application, it's just a program I'm using for the Process), but _patchpath is an absolute path like D:\blah\file.ips. The problem is, the process doesn't work (_patchpath is supposed to be patched with the file temp.txt) if its absolute, but does work if its relative to my app directory. Why is that and how can I fix it?
If I need to be clear please let me know.