Kbase P4301: ADM2: How to reposition Smart Objects to a particular record created during endTransactionValidate.
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/15/2008 |
|
Status: Unverified
GOAL:
ADM2: How to reposition Smart Objects to a particular record created during endTransactionValidate.
FACT(s) (Environment):
Progress 9.X
FIX:
1) In endTransactionValidate of the SDO, set a property called 'RepToThisRowidPlease' in a data-link Smart Object with the adm2 function assignLinkProperty. (requires to create set[propname] and get[propname] in the linked smart object).
DEFINE BUFFER bcust FOR customer.
DEFINE VARIABLE cRowid AS CHARACTER NO-UNDO.
/* for each newly added record Create 2 new records that end with 0 and 2*/
FOR EACH RowObjUpd WHERE RowObjUpd.RowMod = "A":
CREATE bcust.
BUFFER-COPY RowObjUpd EXCEPT RowObjUpd.custnum TO bcust
ASSIGN bcust.NAME = SUBSTR(RowObjUpd.NAME,1,LENGTH(RowObjUpd.NAME) - 1)
In the viewer again. Define variable RepToThisRowidPlease AS CHAR in the definition block of the view. Make the setRepToThisRowidPlease() and getRepToThisRowidPlease() function to set or query this variable.