J
jack
I start process 7zip (http://www.7-zip.org/):
myProc.StartInfo.FileName = Application.StartupPath + @"\7z.exe";
myProc.StartInfo.Arguments = "a -mx9 -y -r " + pathwhat + " " pathwhere
myProc.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
myProc.StartInfo.CreateNoWindow = true;
myProc.StartInfo.UseShellExecute = false;
myProc.StartInfo.RedirectStandardOutput = true;
myProc.Start();
and in timer:
stream = myProc.StandardOutput.ReadLine()
in stream I have everything without current ammount of percent which is show
in console window.
7zip in console looks that:
[..]
Compressing h:\x:\1.a
Compressing h:\x:\2.a
Compressing h:\x:\3.a 33% -> this ist last line at this moment
I need to have a current amount of percent "xx%" in stream which shows in
process console window in the last line (always three last characters).
Can anybody help me ?
jack.
myProc.StartInfo.FileName = Application.StartupPath + @"\7z.exe";
myProc.StartInfo.Arguments = "a -mx9 -y -r " + pathwhat + " " pathwhere
myProc.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
myProc.StartInfo.CreateNoWindow = true;
myProc.StartInfo.UseShellExecute = false;
myProc.StartInfo.RedirectStandardOutput = true;
myProc.Start();
and in timer:
stream = myProc.StandardOutput.ReadLine()
in stream I have everything without current ammount of percent which is show
in console window.
7zip in console looks that:
[..]
Compressing h:\x:\1.a
Compressing h:\x:\2.a
Compressing h:\x:\3.a 33% -> this ist last line at this moment
I need to have a current amount of percent "xx%" in stream which shows in
process console window in the last line (always three last characters).
Can anybody help me ?
jack.