Question Code documentation

Hello,

We developp many programs and I recently did a form of audit of our code base to log the following:
-> wich program call wich program
-> method of passing parameter
-> parameter list with variable name and type and description
-> exemple of calling

The thing is I did all that in excel.

I'm in saerch of solution to do it more automated way with less work on my side.
I was thinking of a text file with the same name and a specific extention or metadata of the file .

Thanks for your advice and help

Best Regards
 
You can automate which programs call which programs using the COMPILE XREF functionality. The compile XREF can tell you who calls who, as well as the parameters.

-> method of passing parameter

I'm not sure what you are looking for here.

-> parameter list with variable name and type and description

For this, as well as probably the example of calling, you are going to want to look at some form of code documentation: ABLDuck as well as HTML and JSON documentation are supported by PCT (see Home) for some more information. This will require you to add documentation comments to the programs (or methods/internal procedures/functions), which will be used to generate this kind of documentation. For example the doc at OpenEdge.Net.HTTP.HttpClient is generated from the code at ADE/netlib/OpenEdge/Net/HTTP/HttpClient.cls at release-12.8.x · progress/ADE . You can add similar documentation to procedural code.
 
Thank you. I will take a look at PCT.

I'm not sure what you are looking for here.

This is what I was doing on my excel file:

comdemail02.wparam-list1inputcharacterc-titletitle of the mailRUN com/demail02.w(INPUT "Bon de réception",
INPUT pdfFile,
INPUT myProg,
INPUT 2,
INPUT YES,
INPUT YES,
INPUT-OUTPUT cDest,
INPUT-OUTPUT cCopy,
INPUT-OUTPUT cObject,
INPUT-OUTPUT cTxt,
INPUT-OUTPUT cImp,
INPUT-OUTPUT lAcc,
INPUT-OUTPUT cPce).
comdemail02.wparam-list2inputcharacterpdfFilepath of file attached
comdemail02.wparam-list3inputcharactermyProgprogramm in charge of generate file attached
comdemail02.wparam-list4inputinteger2
comdemail02.wparam-list5inputlogicaltrue
comdemail02.wparam-list6inputlogicaltrue
comdemail02.wparam-list7input-outputcharactercDestreceiver list
comdemail02.wparam-list8input-outputcharactercCopycopy list
comdemail02.wparam-list9input-outputcharactercObjectmail subject
comdemail02.wparam-list10input-outputcharactercTxtmail text
comdemail02.wparam-list11input-outputcharactercImp
comdemail02.wparam-list12input-outputcharacterlacc
comdemail02.wparam-list13input-outputcharactercPce

I open every program to see wich program they called with the list of parameter and type of parameter. also if they are passed by &SCOPED or by
each variable or a character list
And write down wich programm call wich.

The idea behind that is to facilitate code maintenance and have a clear documentation .
 
Last edited:
Ah, ok. The code documentation procegrams will include INPUT/INPUT-OUTPUT/OUTPUT as well as the datatype of the parameters.

also if they are passed by &SCOPED or by each variable or a character list

This is not done by the code documentation tools. They will look at the comments on the procedure and generate the documentation based on that.
 
Back
Top