This is not the domain of Win32::OLE, as generic "windows" do not have any OLE interface. You seem to want Win32::GuiTest, which has the functions to find window handles and also to send clicks and keystrokes to it.
| [reply] |
Is there any way to tell whether a foreign application has an ole interface?
| [reply] |
| [reply] |
The docs of Win32::GUI say as follows:
Non-owned windows
Every window, even windows not created by your Perl script, can be referenced by Win32::GUI; all you need to know is its "handle", a numerical value that identifies that window. Many functions in the Win32::GUI package return such handles, as for example:
$First = Win32::GUI::GetForegroundWindow();
This value can then be passed to any function that requires a window object; but of course, not being an object, you can't call it as a method:
Win32::GUI::Hide($First); # correct
$First->Hide(); # wrong
Should you need to know the numerical handle of a window created by Win32::GUI, it is stored in its -handle key (this is the value that almost all function really use):
print "Window handle is $Window->{-handle} \n";
CountZero A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
| [reply] [d/l] [select] |
I've been searching for a way to detect a window if it is under the mousecursor but I haven't found a way.. any ideas?
| [reply] |
| [reply] [d/l] |
| [reply] [d/l] |