How to get the number of CPU cycles used by a process

后端 未结 3 847
离开以前
离开以前 2021-02-02 18:19

I have a need to get the number of CPU cycles used by a specific process using C# (or VB.Net). This information is available in the Process properties popup within Sysinternal\

3条回答
  •  清歌不尽
    2021-02-02 18:52

    There is a CodeProject article here: http://www.codeproject.com/KB/system/processescpuusage.aspx

    I think this article will help you do exactly what you are trying to do. Basically they show you 2 ways to do it, one using the managed System.Diagnostics tools and the second using a Win API method call.

提交回复
热议问题