[Stackoverflow] [Progress OpenEdge ABL] Change cell color in a dynamic browse

Status
Not open for further replies.
A

AbsolutistK

Guest
I have tried to color specific cell in a dynamic browse 4GL. However, I was unable to do this for multiple rows. The following code only works for the first row. Current browse

How do I iterate through multiple rows so that I can color the cell ?

Code:
/* DEFINITIONS */
DEFINE TEMP-TABLE ttField
FIELD hHandle AS HANDLE
FIELD cField AS CHARACTER.

/* Before Open Query e.g. procedure initialiseBrowse */
DEF VAR hTemp AS HANDLE.

hTemp = BROWSE {&BROWSE-NAME}:FIRST-COLUMN.

REPEAT:
  CREATE ttField.
  ASSIGN
    ttField.cField = hTemp:NAME
    ttField.hHandle = hTemp.

  IF VALID-HANDLE(hTemp:NEXT-COLUMN) THEN
  hTemp = hTemp:NEXT-COLUMN.
  ELSE LEAVE.
END.


/* Row display - How to do this ?? */
IF /* user clause */ TRUE THEN
DO:
  FOR EACH ttField WHERE LOOKUP("FIELD-LIST", cField) > 0:
    ASSIGN ttField.hHandle:BGCOLOR = 12.
  END.
END.

Continue reading...
 
Status
Not open for further replies.
Top