|
-
Jan 25th, 2003, 01:02 PM
#1
Thread Starter
Fanatic Member
AIM Controlling[resolved]
Im working on a program that does little things to an AIM window. I can do a lot to the window in general, but now i want to be able to send text to the text box. How do i gain control of the text box?
Last edited by Mushroom Realm; Jan 28th, 2003 at 07:57 PM.
-
Jan 25th, 2003, 07:34 PM
#2
There are API functions to traverse the window tree. FindWindowEx might be especially interesting to you. Once you have the HWND you can use SetWindowText to set the window's text.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jan 25th, 2003, 08:02 PM
#3
Thread Starter
Fanatic Member
Does FindWindowEx work for the window or the textbox, or both?
-
Jan 26th, 2003, 05:24 AM
#4
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Jan 27th, 2003, 05:23 PM
#5
Thread Starter
Fanatic Member
In that case couldn't I just use a regular FindWindow call? Either way what should I use as the caption of the textbox?
-
Jan 28th, 2003, 06:00 AM
#6
FindWindow doesn't find child windows.
You'd do something like (in C++, I'm not familiar enough with VB):
Code:
HWND hParent = GetMessengerMainWindow();
// This gets the first edit box (tab order) of
// the messenger:
HWND hChild = FindWindowEx(hParent, NULL, "EDIT", NULL);
// This gets subsequent edit boxes:
hChild = FindWindowEx(hParent, hChild, "EDIT", NULL);
Note that this searches only immediate child windows of the parent. And I don't know how to identify the right edit box if there are several.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|