data: iIncludeLines type standard table of string with header line.
data: iTokens type standard table of stokes with header line.
data: iKeywords type standard table of text20 with header line.
data: iStatements type standard table of sstmnt with header line.
data: waTokens type stokes.
data: waInclude type tInclude.
data: waIncludeExists type tInclude.
data: maxLines type i.
data: nextLine type i.
data: castProgramName type program.
* Read the program code from the textpool.
castProgramName = programName.
read report castProgramName into iIncludeLines.
append INCLUDE to iKeywords.
scan abap-source iIncludeLines tokens into iTokens with includes statements into iStatements keywords from iKeywords.
clear iIncludeLines[].
maxLines = lines( iTokens ).
loop at iTokens where str = INCLUDE and type = 'I'.
"自己写处理逻辑
ENDLOOP.
ABAP根据程序去找INCLUDE程序
最新推荐文章于 2023-02-08 18:09:49 发布