积极答复者
怎样用C#写进程监控服务

问题
答案
-
你可以尝试一下这个帖子中的代码,是通过WMI来监控进程的创建的:
Event to detect when a new process is created in windows
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.- 已编辑 CaillenModerator 2014年1月10日 6:49
- 已标记为答案 50 个字符 2014年1月14日 13:53
全部回复
-
你好:
在.net中已经提供了System.Diagnostics.Process类,通过这个类你可以获取到当前进程的信息:
Process[] ps = Process.GetProcesses(); foreach(Process p in ps){ Console.WriteLine("Process: {0} ID: {1}", p.ProcessName, p.Id); }
你也可以查看进程的其它信息,具体可以参考MSDN文档。
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey. -
你可以尝试一下这个帖子中的代码,是通过WMI来监控进程的创建的:
Event to detect when a new process is created in windows
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.- 已编辑 CaillenModerator 2014年1月10日 6:49
- 已标记为答案 50 个字符 2014年1月14日 13:53
-