当前位置: 代码迷 >> ASP >> asp.net 访问 exe资料的方法
  详细解决方案

asp.net 访问 exe资料的方法

热度:480   发布时间:2012-08-22 09:50:35.0
asp.net 访问 exe文件的方法
调用Process类,strFileName是被调用exe文件的路径
public void CallSteven(string strFileName)
        {
            System.Diagnostics.Process prc = new System.Diagnostics.Process();
            try
            {
                prc.StartInfo.FileName = strFileName;
                prc.Start();
            }
            catch (Exception exU)
            {
                if (!prc.HasExited)
                {
                    prc.Close();
                }

                throw new Exception(exU.Message.ToString());
            }
        }

?

  相关解决方案