What I need to do is to read the edit boxes, in this case a client address, from a commercial app, modify the address, and then replace the data on the application screen. I understand that I need to use the Window handle properties to do this but I am at a loss as to how to do this. Can anyone point me in the right direction to find some help on this.


Re: Visual Basic Language How to Modify Edit Boxes in Another App?


Anybody have any suggestions


Re: Visual Basic Language How to Modify Edit Boxes in Another App?

Bruno Yu - MSFT


1. According to your description, I would like to provide you some related information on Window handle (hWnd).

Start another program using Shell and get its Window handle (hWnd)

The Shell function starts a new program and returns the new process's task ID or zero if it cannot execute the program. This program then calls function InstanceToWnd to find the Window handle corresponding to the task ID. To prove the Window handle is correct, the program finishes by calling GetWindowText to read the new program's caption.

2. PPT97: Sample VB Code to Obtain Window Handle

This article provides a sample Microsoft Visual Basic for Applications macro that uses the FindWindow API to obtain a window handle to the main PowerPoint window.

A window handle is important if you plan to call Windows API procedures in your code. Many Windows API procedures require a window handle as one of the parameters.

Hope the informaion above can help you.