Consultor Eletrônico



Kbase P26566: How to access an ADM1 non displayed browse table field on VA
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   6/5/2003
Status: Unverified

GOAL:

How to access an ADM1 non displayed browse table field on VALUE-CHANGED event.?

FACT(s) (Environment):

Windows

FACT(s) (Environment):

Progress 8.3x

FIX:

Given an ADM-1 smart data browse object built against the sports.customer table to exclude the customer.country field from its display list.

The following browse VALUE-CHANGED event trigger messages the country field value for the currently selected customer and invokes a local 'local-assign-record' procedure to assign the customer.country field a new value.

ON VALUE-CHANGED OF br_table IN FRAME F-Main
DO:
/* This ADM trigger code must be preserved in order to notify other
objects when the browser's current row changes. */
{src/adm/template/brschnge.i}

MESSAGE customer.country
VIEW-AS ALERT-BOX INFO BUTTONS OK.
RUN local-assign-record.
END.

The 'local-assign-record' procedure requires that at least one of the browse fields be enabled. And it could look somthing like:

PROCEDURE local-assign-record :
/*------------------------------------------------------------------------------
Purpose: Override standard ADM method
Notes:
------------------------------------------------------------------------------*/

/* Code placed here will execute PRIOR to standard behavior. */

/* Dispatch standard ADM method. */
RUN dispatch IN THIS-PROCEDURE ( INPUT 'assign-record':U ) .

/* Code placed here will execute AFTER standard behavior. */
ASSIGN
Customer.Country = "PROCANDO!".

END PROCEDURE.