Solved

How do use SendMessage to write into another app's window.

Posted on 2006-06-14
2
299 Views
Last Modified: 2013-12-25
I have a script that I've used to write text into the window of another application.  By using the FindWindow and FindWidowEx api funciton calls, I was able to get that window's handle and then use the SendMesage function to actually write into it.  I want to do the same thing but write to a window of another application.  The problem I'm having is that I don't know the window hierarchy of this app so don't know which window this is a child of.  Is there any way to determine all of the children of a particular window and how to I access the handle of each?

Thanks!
 
0
Comment
Question by:planetiowa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 86

Accepted Solution

by:
Mike Tomlinson earned 250 total points
ID: 16905293
If you have Visual Studio then there is a free tool that came with it called Spy++ that you can use to view the window structure.

If you don't have Visual Studio then try out the free WinSpector:
http://www.windows-spy.com/
(I've used it before without any problems.)
0
 

Author Comment

by:planetiowa
ID: 16906682
Thanks - that's exactly what I needed!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question