DEOControlFocusObject - cBaseLocalControlHost
Returns the object handle of the object representing the currently focused control on the client if the control supports the full data binding interface
Type: Function
Return Data Type: Handle
Syntax
Function DEOControlFocusObject Returns Handle
Call Example
Get DEOControlFocusObject to HandleVariable
Description
Call DEOControlFocusObject to return the DataFlex object handle of the server-side object that represents the currently focused object on the client.
Data binding occurs when the Entry_Item command is applied. The data binding interface includes all Request_Save, Request_Find, Request_Delete and Request_Clear messages that are processed by the attached Server DataDictionary object (DDO).
Control classes such as cWebForm and cWebColumn are examples of classes that support the data binding message interface. Container classes such as cWebCard, cWebPanel and cWebView support the DEO interface, but not the full data binding interface (see DEOFocusObject for more information).
Use DEOControlFocusObject when you want to send a message that is part of the data binding interface, to the focused object. DEOControlFocusObject can be used in the OnClick event of a menu item or toolbar button (cWebMenuItem) to send some message to the object that had the focus when the menu item was selected.
Sample
This sample sends Request_Find to the focus object, but only if the focused object supports the Request_Find (and other data binding messages).
Procedure OnClick
Handle hoFocus
Get DEOControlFocusObject to hoFocus
If hoFocus Begin
Send Request_Find of hoFocus GE
End
End_Procedure
See Also
FocusObject | DEO_Object | DEO_Control_Object
Return Value
The DataFlex object handle of the server-side object that represents the currently focused object on the client. If the DataFlex object does not support the data binding message interface, then 0 is returned.