In following this thread (no small task) I'm wondering if Dan simply
wants the Active Window.
It's possible, but there are dangers.
The GetActiveWindow function is a function that returns a handle to a
window—in this case, the application window that's currently active.
The GetWindowText function takes a handle to a window and returns
that window's caption if it has one.
Correct, but I'm not entirely certain if the window title is constant
or not. If the title only contains the active document name or
something like that.
But if the window title will always have some identifying text that
other applications won't have (for example, it will always say
"Foobar", and you can be certain that other applications won't have
that same text in any of their window titles), then you can use
GetActiveWindow like you suggest. Just be aware that another
application could "hijack" yours by having a title with the proper
keyword in it.
HTH!
~Aaron
--
REAL World 2005 - The REALbasic User Conference
March 23-25, 2005, Austin, Texas
<http://www.realsoftware.com/realworld>
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>
|