LocCapture

Description: Capture Locator Input. This statement captures all subsequent input from the locator device and routes it to a specific window.
Returns: TRUE if capturing. Invalid otherwise.
Usage: Steady State only.
Function Groups: Locator,  Window
Related to: WinXLoc | WinYLoc | XLoc | YLoc
Format: LocCapture(Object, Enable)
Parameters:  
Object  
Required. Any expression that returns an object value of a window or an object within a window whose coordinate system is to be used for locator coordinate reports until capture is released.
Enable  
Required. Any logical expression. If true (non-0), the locator input will be captured by the window containing the module expressed by Object. If false (0), the locator capture is yielded.
Comments: This statement captures all locator input and routes it to the window containing the module instance that issued the LocCapture statement. This is most useful when there are child windows present that are graphically in front of the window with capture. With capture disabled (the normal condition), the coordinates returned to a WinXLoc(Self( )) would change from being relative to the parent window's coordinate origin to the child window's coordinate origin as the locator moved over the child window. With capture enabled, the coordinates would always be relative to the parent window's coordinate origin, no matter which window the locator was over.

Example:

LocCapture(Self(), 1);