@iBlachu
Short answer is no. Documentation states it could be done but I never got it to work.
A popular misconception among DCL developers is to blend gathering user input with program execution. Bad idea.
The proper way is to:
1. Gather user input (when the "accept" event is triggered),
2. Test user input (via some sort of COND gauntlet),
3. Save user input (as a LIST using ONE session gremlin for the current program),
4. Close the dialog, and
5. Execute.
If in the COND gauntlet one tile does not satisfy the requirements (example would be a letter was entered instead of an integer), Alert the user, MODE_TILE = 2 the tile, and return to the dialog by sending back a nil.
The following structure is a simple example (that is simplified):
Edit box "Edi01" expects an integer.
(action_tile "accept" "(if (MyProgn_GET) (done_dialog 1))")
(defun MyProgn_GET ()
(cond
((not (distof (get_tile "Edi01"))) (alert "Edit Box expects an Integer") (mode_tile "Edi01" 2) nil) ;note that ATOI is not used. If it fails, ATOI returns 0 which is an integer!
;;a second test of Edi01 needed here to see if it is indeed an integer and not a REAL.
...
(T (setq MyGremlin (list (get_tile "Edi01"))))
);cond
);end MyProgn_GET
Another reoccurring issue I see in this forum is the tiles are not initialized. For example, a TOGGLE tile has 3 possible returns: "0", "1", and nil. Where nil is due to the tile is not initialized.
Edit boxes similar: empty string, string, and nil.
Between the new_dialog and start_dialog add a "Initialization" section and build the session gremlin (as a LIST) if it does not exist. From there populate (initialize) the [/ALL] interactive tiles (except BUTTON).
;** Initialize **
(or MyGremlin (setq MyGremlin (list "1")))
;** Set Tile **
(set_tile "Edi01" (nth 0 MyGremlin))
;** Mode Tile **
;** Action Tile **
(action_tile "accept" "(if (MyProgn_GET) (done_dialog 1))")
Any other action tile you develop will be for dialog display such as disabling a tile, row, or column, or to switch out the contents of a list box, set focus to another tile, initialize another dialog, etc. The action tile should not direct to an execution part of your code that does not relate to the dialog display.
When the dialog is reopened during the same editing session, the dialog will show the previous state the dialog was in.
Finally, when communicating with radio_buttons, add a key="Rad00" to the container that is holding the radio buttons and communicate with the container. Yes it is true that radio buttons do not require radio containers (row / column), but these containers are there for this reason.
Pop quiz next week.
Scot-65
A gift of extraordinary Common Sense does not require an Acronym Suffix to be added to my given name.