62,074
社区成员
发帖
与我相关
我的任务
分享
Process myProcess = new Process();
string fileName =Server.MapPath( @"bin\ExportExcel.exe");
string para = @"qd_20150113-01 ";
ProcessStartInfo myProcessStartInfo = new ProcessStartInfo(fileName, para);//传递给exe参数,接收可以在EXE处理
StringBuilder sb = new StringBuilder();
myProcess.StartInfo.UseShellExecute = false;
myProcess.StartInfo = myProcessStartInfo;
myProcess.Start();
while (!myProcess.HasExited)
{
myProcess.WaitForExit();
}
//string output = myProcess.StandardOutput.ReadToEnd();
int returnValue = myProcess.ExitCode;
Response.Write(returnValue);