The databases connected in Progress… use NUM-DBS and LDBNAME.

DEF VAR i AS INTEGER NO-UNDO.
IF NUM-DBS eq 0 THEN DISPLAY  “No tatabases connected”.
ELSE DO:
DISPLAY  “Connected databases:” .
DO i = 1 TO NUM-DBS:
message LDBNAME(i) VIEW-AS alert-box.
END.
END.

😀