string text = ""; string strUser = "894128"; string strPath = HttpContext.Current.Server.MapPath("~/OfficeUpload/"); System.IO.File.WriteAllText(strPath + strUser + ".txt", text); ProcessStartInfo psi = new ProcessStartInfo(); psi.FileName = Path.GetFileName(strPath + "/StockMergeRpt.exe"); psi.WorkingDirectory = Path.GetDirectoryName(strPath + "/StockMergeRpt.exe"); psi.Arguments = "-i " + strUser + ".txt -o " + strUser + ".doc"; Process.Start(psi);
沒有留言:
張貼留言