/* load cobol program in memory (FCBLPGM allocated to member)*/
"EXECIO * DISKR FCBLPGM (FINIS STEM PgmSrc."
/* loop on program contents scanning for COPY */
Do P = 1 To PgmSrc.0
Parse Upper Var PgmSrc.P 1 . 7 Comment 8 CblLine 73 .
If Comment = '*' Then Iterate
If Word(CblLine,1) <> 'COPY' Then Iterate
CopyName = Strip(Word(CblLine,2),'.')
Say "Found COPY. Name is "CopyName
End
Joined: 08 May 2006 Posts: 171 Location: Dublin, Ireland
Perhaps use ICEMAN/ICETOOL to:
..... extract the lines with substring " COPY "
..... process the results in workfile.
..... produce your "nice report" from the workfile ?