Kbase P82879: How to trap entry event on an enabled Dynamic Browse field
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/16/2008 |
|
Status: Unverified
GOAL:
How to trap entry event on an enabled Dynamic Browse field
FACT(s) (Environment):
Dynamics
FIX:
To trap the "entry" event on a enabled field in the browse you should edit the the custom super procedure of the dynamic browser.
The below example will show how to trap the entry of the first browse column; However, since you get the browse handle, you can get the handle of any browse column, so it can be written code for any browse field.
1. In the definition section define the variables:
DEFINE VARIABLE hBr AS HANDLE NO-UNDO.
DEFINE VARIABLE hColumn AS HANDLE NO-UNDO.
PROCEDURE InitializeObject:
/*------------------------------------------------------------------------------
Purpose:
Parameters:
Notes:
------------------------------------------------------------------------------*/
RUN SUPER.
hBr = DYNAMIC-FUNCTION('getBrowseHandle' IN TARGET-PROCEDURE).
IF NOT VALID-HANDLE(hBr) THEN RETURN.
hColumn = hBr:FIRST-COLUMN.
ON 'entry':U OF hColumn PERSISTENT RUN FirstColumn-ENTRY IN THIS-PROCEDURE.
END PROCEDURE.
PROCEDURE FirstColumn-ENTRY:
/*------------------------------------------------------------------------------
Purpose:
Parameters:
Notes:
------------------------------------------------------------------------------*/
MESSAGE 'FirstColumn-ENTRY'
VIEW-AS ALERT-BOX INFO BUTTONS OK.
END PROCEDURE.