搜索长整型数 - FindInt
函数简介
搜索指定范围内的长整型数。
接口名称
FindInt
DLL调用
long FindInt(long instance, long hwnd, string addr_range, long int_value_min, long int_value_max, int type);
参数说明
| 参数名 | 类型 | 说明 |
|---|---|---|
| instance | 长整数型 | OLAPlug对象的指针,由 CreateCOLAPlugInterFace 接口生成。 |
| hwnd | 长整数型 | 窗口句柄 |
| addr_range | 字符串 | 地址范围 |
| int_value_min | 长整数型 | 最小值 |
| int_value_max | 长整数型 | 最大值 |
| type | 整数型 | 整数类型(0:32位,1:16位,2:8位,3:64位) |
示例
C++
long instance = CreateCOLAPlugInterFace();
// hwnd 为目标窗口句柄
// 搜索32位整数,值范围100~200
long strPtr = FindInt(instance, hwnd, "0x00400000-0x7FFFFFFF", 100, 200, 0);
char* result = GetStringFromPtr(strPtr);
printf("搜索结果: %s\n", result); // 输出如 "0x12345678|0x12345688"
FreeStringPtr(strPtr);
Python
# 待补充
返回值
返回字符串的指针,格式: "addr1|addr2|...|addrn"。
注意事项
- 返回的字符串指针需调用 FreeStringPtr 释放内存。
