Purpose
Sets which window will be the parent of dialog boxes that are yet to be created.You can issue this statement from the MapBasic window in MapInfo Pro.
Syntax
Set Application Window HWND
HWND is an integer window handle, which identifies a window.
Description
This statement sets which window is the application window. Once you set the application window, all MapInfo Pro dialog boxes have the application window as their parent. This statement is useful in "integrated mapping" applications, where MapInfo Pro windows are integrated into another application, such as a Visual Basic application.
In your Visual Basic program, after you create a MapInfo Object, send MapInfo Pro a Set Application Window statement, so that the Visual Basic application becomes the parent of MapInfo Pro dialog boxes. If you do not issue the Set Application Window statement, you may find it difficult to coordinate whether MapInfo Pro or your Visual Basic program has the focus.
Issuing the command Set Application Window 0 will return MapInfo Pro to its default state. This statement re-parents dialog box windows. To re-parent document windows, such as a Map window, use the Set Next Document statement.
For more information on integrated mapping, see the MapBasic User Guide.
See Also:
Set Next Document statement