[C#] NETSTAT 구하기


Process p = new Process();          
StreamReader sr;          
ProcessStartInfo startInfo = new ProcessStartInfo("netstat");
startInfo.Arguments = "-s";
startInfo.UseShellExecute = false;           
startInfo.RedirectStandardOutput = true;          
startInfo.CreateNoWindow = true;
p.StartInfo = startInfo;
p.Start();
sr = p.StandardOutput;
System.Windows.Forms.MessageBox.Show(sr.ReadToEnd());    



+ Recent posts