作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
很简单,通过属于dll父进程的类名找到顶层窗口。从网上查到的应该是
EnumWindows
枚举所有顶层窗口EnumWindowsProc
中比较枚举窗口的类名 GetClassName
与指定的名称 GetWindowThreadProcessId
是否与 dll 父 pid 相同但是我遇到了一个障碍,如何获取dll loader的PID?或者也许还有另一种方法可以通过类名查找父窗口?
最佳答案
你能不能只使用 GetCurrentProcessId ?
您还可以使用 PSAPI功能,但这可能有点矫枉过正......
关于DLL 中的 C++ FindProcessWindow,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15559671/
很简单,通过属于dll父进程的类名找到顶层窗口。从网上查到的应该是 EnumWindows 枚举所有顶层窗口 在 EnumWindowsProc 中比较枚举窗口的类名 GetClassName 与指定
我是一名优秀的程序员,十分优秀!