How to Find a Window Handle Based on an Instance Handle (127030)
The information in this article applies to:
- Microsoft Visual Basic Standard Edition for Windows 2.0
- Microsoft Visual Basic Standard Edition for Windows 3.0
- Microsoft Visual Basic Professional Edition for Windows 2.0
- Microsoft Visual Basic Professional Edition for Windows 3.0
This article was previously published under Q127030 SUMMARY
The Shell function in Microsoft Visual Basic is used to execute an
application. Often, it is useful to get a Window handle (hWnd) to the
application so you can manipulate it using the Windows APIs. Unfortunately,
the Shell function returns an Instance handle (hInstance), which is
different from a Window handle. This article shows by example how to use
the GetWinHandle() function to return a Window handle based on an Instance
handle.
Modification Type: | Major | Last Reviewed: | 12/9/2003 |
---|
Keywords: | kbcode KB127030 |
---|
|