MCPcopy Create free account
hub / github.com/HelloBush/Java_MHXYdemo / EnumWindowByProcess

Method EnumWindowByProcess

src/pkgDm/Dm2Java.java:142–144  ·  view source on GitHub ↗

根据指定进程以及其它条件,枚举系统中符合条件的窗口,可以枚举到按键自带的无法枚举到的窗口 @param process_name 程映像名.比如(svchost.exe). 此参数是精确匹配,但不区分大小写 @param title 窗口标题. 此参数是模糊匹配. @param class_name 窗口类名. 此参数是模糊匹配. @param filter 取值定义如下 1 : 匹配窗口标题,参数title有效 2 : 匹配窗口类名,参数class_name有效 4 : 只匹配指定映像的所对应的第一个进程. 可能有很多同映像名的进程,只匹配第一个进程的.<br/

(String process_name,String title,String class_name,int filter)

Source from the content-addressed store, hash-verified

140 * @return 返回所有匹配的窗口句柄字符串,格式"hwnd1,hwnd2,hwnd3"
141 */
142 public String EnumWindowByProcess(String process_name,String title,String class_name,int filter){
143 return Dispatch.call(dm, "EnumWindowByProcess", process_name,title,class_name,filter).getString();
144 }
145
146 /**
147 * 查找符合类名或者标题名的顶层可见窗口

Callers

nothing calls this directly

Calls 2

callMethod · 0.95
getStringMethod · 0.45

Tested by

no test coverage detected