开发者

via Win32 API how would you get the value of a class of SysListView32

I have a c# app that reads (with thanks to this forum) the values of a native windows app via the win32 API, I can get all the text from boxes of class Edit but there is some data presented in a SysListView32 control for w开发者_开发问答hich I can get the handle.

So given the handle how do I get the data within the list view?

thanks


VirtualAllocEx
WriteProcessMemory to initlize LVITEM
SendMessage(hwnd, LVM_GETITEM, WPARAM, LPARAM)
ReadProcessMemory
VirtualFreeEx
  1. Need to allocate/free additional buffers if text is included
  2. Does not work on Windows Mobile
  3. Does not work across platforms, you need to compile x86 and x64 targets for 32 and 64 bit processes) and marshal the APIs with the correct bitness.
  4. Does not work if blocked by UIPI.
  5. Have race condition with the target process


A far easier way would be to inject a DLL, which would then obviously be inside the aforementioned process.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜