Windows CE 6.0 - 我可以获取应用程序进程的总句柄数吗? [英] Windows CE 6.0 - Can I get the total handle count of my application process?

查看:163
本文介绍了Windows CE 6.0 - 我可以获取应用程序进程的总句柄数吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我为Windows Mobile 6.0设备编写了一个需要全天候运行的程序。



出于诊断目的,我希望我的程序能够定期报告进程占用的句柄数和内存量。



我的程序是一个Compact Framework应用程序(C#),但是我确实调用了windows api函数信息。



哪些函数会给我这些信息?



这个遗留应用程序使用CF 2.0所以进程类没有句柄计数。

I have written a program for a Windows Mobile 6.0 device that needs to run 24/7.

For diagnostic purposes, I want my program to be able to periodically report the number of handles and the memory that the process has consumed.

My program is a Compact Framework app (C#), but I call windows api functions for certain information.

What functions will give me that information?

This legacy app uses CF 2.0 so the Process class does not have the handle count.

推荐答案

Windows API有一个GetProcessHandleCount 和.net有 Process.HandleCount



它们都不合适,所以你需要更好地保护手柄。打开或更安全的代码后直接关闭。



WM 6.0真的是过时的垃圾; - )
The windows API hast GetProcessHandleCount and the .net has Process.HandleCount.

It both wont fit, so you need to better protect the handles. Direct close after open or more secure code.

WM 6.0 is really outdated rubbish ;-)


这篇关于Windows CE 6.0 - 我可以获取应用程序进程的总句柄数吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆