Trying to help you on all the topics of your last 3 posts (you better open a separate thread for each subject)
Regarding passing/returning information from SUBDIALOGs, yes you must use PUBLIC module variables. No, you cannot make local declaractive DIALOG variables public (these are local to the DIALOG block, like variables defined in FUNCTIONs). You can also define functions beside the declarative dialog, to encapsulate module variables, and add some code arround. No you cannot execute procedural code inside a procedural DIALOG block (the IF subDialogs.inputResult = 3 THEN example)
Modules defining combobox initializers must have been loaded to make the initializer work. You need to call another function from that module before the OPEN WINDOW / OPEN FORM + DISPLAY FORM instructions.
Regarding the "base_globals" case, to me this looks like a candidate for a configurable utility module, where you could define PRIVATE module variables, that can be set by PUBLIC module functions (to set the dbname for ex), and execution functions (like connecting to the database). Think encapsulation and modularisation:
PRIVATE DEFINE dbname VARCHAR(50)
PUBLIC FUNCTION set_dbname(n)
DEFINE n VARCHAR(50)
LET dbname = n
END FUNCTION
PUBLIC FUNCTION do_connect()
DATABASE dbname
END FUNCTION
About the second point (g_DBNAME/FGL_GETENV), sorry but I don't get it. You better provide a little sample to reproduce the problem to let us identify if the behavior described is expected or is a bug...
Regarding the "next field" case:
Here again, a little sample would be appreciated to let us understand, here some remarks...
I think that you should design your dialogs so that you don't have to add particular code to jump to a specific field in a given condition.
The field navigation should be natural and implicit.
If the "always in edit mode" for record lists (INPUT ARRAY semantics) is not mandatory, consider using DISPLAY ARRAY with modification triggers (ON APPEND, ON INSERT, ON DELETE, ON UPDATE) - It's easier to deal with a DISPLAY ARRAY as with all special cases of INPUT ARRAY.
I think you should have a look at the latest version of the documentation that is under construction.
It has updated topics that will help you to better understand dialog programming.
https://intranet.4js.com/distrib/manuals/FOURJS/FJSONLY/trunk/fjs-fgl-latest-manual-html-draft/index.html#c_fgl_prog_dialogs.htmlYou need a EAP login to access this doc.
Seb