How to access related field on grid by peoplecode
How to access related field on grid by peoplecode of peoplesoft.
My requirement:
How to access related field DESCR100 of table CNTRC_TRAN and field EMPLID3 in all row of grid.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
Local Rowset &rsLvl1 = GetLevel0()(1).GetRowset(Scroll.CNTRC_TRAN); Local Field &fldCtrl, &fldRelated;rem loop through each row in the grid; rem WinMessage(&rsLvl1.ActiveRowCount, 0); For &j = 1 To &rsLvl1.ActiveRowCount; rem get the control field; &fldCtrl = &rsLvl1(&j).GetRecord(Record.CNTRC_TRAN).GetField(Field.EMPLID3); rem now get the related display field; &fldRelated = &fldCtrl.GetRelated(EMP_NAME.DESCR100); WinMessage(&fldRelated.Value, 0); &fldRelated.Value = ""test_related_feild""; &fldRelated.Visible = True; End-For; |