好像调用不了  服务器那边没反应
我的是独享主机可以自己配置
请教一下该怎么解决

解决方案 »

  1.   

    一般web结构不允许执行服务器上的exe,否则从客户端什么都能干了,有重大安全问题。你要达到什么样的目的,可以变通的,不要循一个思路走
      

  2.   

    我调用服务器CMD失败;代码:
                 
    Process p = new Process();             p.StartInfo.FileName = "cmd";             p.StartInfo.UseShellExecute = false;             p.StartInfo.RedirectStandardInput = true;             p.StartInfo.RedirectStandardOutput = true;             p.StartInfo.RedirectStandardError = true;             p.StartInfo.CreateNoWindow = true;             p.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;             p.Start();             string strOutput = null;             p.StandardInput.WriteLine(xxx【xxx这里是个CMD命令 在服务器那边我运行没问题】);             p.StandardInput.WriteLine("exit");             strOutput = p.StandardOutput.ReadToEnd();             Console.WriteLine(strOutput);             p.WaitForExit();             p.Close();
      

  3.   

    原来远程命令存在安全漏洞,如果服务器打.net2.0的补丁,web就会报错
    我原先做的一个程序和LZ类似,后来没找到解决方案,不了了之了
    关注一下