The Locate_Mode property provides several flexible methods for auto positioning container panels in your program. The following modes are supported:
Constant | Meaning | |
NO_LOCATE | No auto-location is performed. The object must be manually located by using the set location message. |
|
POPUP_LOCATE | This causes the object to locate itself relative to the object (and item) that invoked it. It is ideal for locating popup modal objects (like selection-lists). The position at which this object pops up depends on the values of its column_offset and row_offset properties. |
CENTER_ON_SCREEN | This causes the container to appear in the center of the screen (first monitor in the case of multiple monitors). |
CENTER_ON_PANEL | This causes the container to centered within the current main program panel. |
CENTER_ON_PARENT | This causes the container to appear in the center of its parent container. |
SMART_LOCATE | This mode "just does the right thing". This message will cause the object to apply the best locating strategy for current conditions. If the object is a modal popup (modal_state is true) and there is an invoking object it will locate relative to the invoking object (popup_locate), else, if the object already has been assigned a location it will use that location. else, if main-panel exists it will center within that panel (center_on_panel), else, it will center itself on the screen (center_on_screen). All panels default to this mode. This causes modal popup panels to locate relative to their parent and modeless panels to appeared centered unless explicitly located. |