[Stackoverflow] [Progress OpenEdge ABL] What's the idea behing W-, P- and I-files?

Status
Not open for further replies.
D

Dominique

Guest
I'm working with appBuilder and procedure editor in Progress Release 11.6.

As mentioned in some previous questions, regularly I'm having problems with the appBuilder, not wanting to open files, corrupting them (deleting parts of source code), ..., one of the reasons now seems to be the limit that a procedure cannot exceed 32K, comments included.

At first I thought "Are we back in the stone age?", pardon my reaction.

But now I start thinking that we are completely abusing the whole concept, therefore I'd like to show my view on W-, P- and I-files, please confirm (or correct):

W-files are meant only to contain GUI definitions, like a form with some frames, buttons, fill-in fields, ..., any real programming needs to be done in P-files.
P-files contain the real intelligence: there the procedures and functions are elaborated, that can be used by the rest of the P-files, or finally by the W-files.
I-files are just there to include general behaviour.

Let me give you an example:

W-file:

Code:
DEFINE VARIABLE combo_information VIEW-AS COMBOBOX /* with some information on the content, if this is static */
...
ON CHOOSE OF combo_information DO:
  RUN very_large_procedure.
END.
...
{about.i} /* see here-after */
...

P-file:

Code:
PROCEDURE very_large_procedure:
DO /* a lot */
END.

I-file (about.i):

Code:
/* Describes the help-about menu item */

While working like this (only putting the GUI-related things in the W-file and let the "real" programming be done in the P-files), the mentioned 32K limit will never be reached. In top of that, adding a procedure can be done easily, the appBuilder will not delete it as the appBuilder won't ever open the P-file.

Is my view correct (and what about the I-files)?
In case yes: one technical question: how can I launch a procedure from a P-file inside a W-file? (Obviously, the mentioned example can't work as in the W-file I did not mention where to look for the very_large_procedure)

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