杀毒

来源:互联网 发布:dota1618牛蛙淘宝店 编辑:程序博客网 时间:2024/04/30 07:57
 Process process = new Process();
        //设定程序名
        process.StartInfo.FileName = ConfigurationManager.AppSettings["sdPath"].ToString() + @"\360sd.exe";
        //要被杀毒的文件
        process.StartInfo.Arguments = @"E:\1.jpg";
        //关闭Shell的使用
        process.StartInfo.UseShellExecute = false;
        //重定向标准输入
        process.StartInfo.RedirectStandardInput = true;
        //重定向标准输出
        process.StartInfo.RedirectStandardOutput = true;
        //重定向错误输出
        process.StartInfo.RedirectStandardError = true;
        //设置不显示窗口
        process.StartInfo.CreateNoWindow = true;
        //ping的显示结果
        string ss_PingResult = string.Empty;
        //设置不显示窗口
        process.StartInfo.CreateNoWindow = true;
        process.Start();
        process.StandardInput.AutoFlush = true;
        process.StandardInput.WriteLine("exit");
原创粉丝点击