当前位置: 技术问答>java相关
如何得到当前激活的应用程序窗口的句柄?
来源: 互联网 发布时间:2015-06-21
本文导语: 如何得到当前激活的应用程序窗口的句柄? 这样我可以对应用程序中控件进行操作。 不仅是java程序,还有windows程序。 请各位踊跃发言,谢谢. | window程序可以使用 CWnd::GetActiveWindow static CWnd* PASCAL ...
如何得到当前激活的应用程序窗口的句柄?
这样我可以对应用程序中控件进行操作。
不仅是java程序,还有windows程序。
请各位踊跃发言,谢谢.
这样我可以对应用程序中控件进行操作。
不仅是java程序,还有windows程序。
请各位踊跃发言,谢谢.
|
window程序可以使用
CWnd::GetActiveWindow
static CWnd* PASCAL GetActiveWindow( );
java中可以试一试
java.awt
Class KeyboardFocusManager
java.lang.Object
|
+-java.awt.KeyboardFocusManager
public Window getActiveWindow()
Returns the active Window, if the active Window is in the same context as the calling thread. Only a Frame or a Dialog can be the active Window. The native windowing system may denote the active Window or its children with special decorations, such as a highlighted title bar. The active Window is always either the focused Window, or the first Frame or Dialog that is an owner of the focused Window.
CWnd::GetActiveWindow
static CWnd* PASCAL GetActiveWindow( );
java中可以试一试
java.awt
Class KeyboardFocusManager
java.lang.Object
|
+-java.awt.KeyboardFocusManager
public Window getActiveWindow()
Returns the active Window, if the active Window is in the same context as the calling thread. Only a Frame or a Dialog can be the active Window. The native windowing system may denote the active Window or its children with special decorations, such as a highlighted title bar. The active Window is always either the focused Window, or the first Frame or Dialog that is an owner of the focused Window.