获取模块大小 - GetModuleSize
函数简介
获取模块大小。
接口名称
GetModuleSize
DLL调用
int GetModuleSize(long instance, long hwnd, string module_name);
参数说明
| 参数名 | 类型 | 说明 |
|---|---|---|
| instance | 长整数型 | OLAPlug对象的指针,由 CreateCOLAPlugInterFace 接口生成。 |
| hwnd | 长整数型 | 窗口句柄 |
| module_name | 字符串 | 模块名 |
示例
C++
long instance = CreateCOLAPlugInterFace();
// hwnd 为目标窗口句柄
// 获取模块大小
int moduleSize = GetModuleSize(instance, hwnd, "game.exe");
printf("模块大小: %d 字节\n", moduleSize);
Python
# 待补充
返回值
成功返回模块大小,失败返回0。
