Pequeno programa que não pode faltar em nenhum projeto SAP.
Facilita a vida do funcional e do profissional Abap. A partir da transação o usuário poderá selecionar todas as exits existentes na mesma.
report Z_BUSCA_EXIT no standard page heading.
*------------------------------------------------------------------*
* *
* *
* Este programa pesquisa todas as ampliações e suas respectivas *
* funções para modificações de acordo com sua necessidade. *
* Eventualmente, poderá haver funções dentro destas ampliações *
* que não atenda o interessado, pois a pesquisa será efetuada *
* levando-se em conta a classe de desenvolvimento. Sabe-se, *
* entretanto, que o R3 prima por considerar cada processo dentro *
* uma unica classe de desenvolvimento. *
* *
*------------------------------------------------------------------*
* Tabelas para pequisar ampliações MODSAP MOSAPA
tables :
tstc, " Códigos transação SAP
tstct, " Textos das transações
tadir, " Catálogo de objetos repository
trdir, " Programas com seus atributos
tfdir, " Módulos de funções
modsapt, " Textos breves ampliações SAP
modsap,
tftit,
enlfdir. " Atributos adicionais das funções
data: begin of mylist occurs 50. " Internal table hierarchy
include structure snodetext.
data: end of mylist.
data:
begin of tp occurs 10,
id(01),
nr(08),
text(255),
length like textpool-length,
end of tp.
data: txt_report like dokhl-object. "Report name for documentation
data: f15 type c, w_campo(30).
data :
t_objetos like tadir occurs 0 with header line,
v_classe like tadir-devclass,
cursor(30).
selection-screen begin of block b0 with frame.
selection-screen begin of block b1 with frame.
selection-screen begin of block b2 with frame.
selection-screen begin of block b3 with frame.
parameters :
p_tcode like tstc-tcode obligatory default 'VA01',
p_langu like sy-langu obligatory default 'PT'.
selection-screen end of block b3.
selection-screen end of block b2.
selection-screen end of block b1.
selection-screen end of block b0.
select single * from tstc where tcode eq p_tcode.
start-of-selection.
set pf-status 'TELA'.
get cursor field cursor.
read textpool sy-repid into tp language sy-langu.
loop at tp where id = 'R'.
set titlebar '001' with tp-text.
exit.
endloop.
perform monta_tabela.
perform build_tree.
perform draw_tree.
at user-command.
case sy-ucomm.
when 'BACK' or 'EXIT' or 'CANC'.
set screen 0.
leave program.
when others.
endcase.
top-of-page.
format color col_positive intensified off.
write:/(19) 'Codigo Transação - ',
20(20) p_tcode,
45(50) tstct-ttext.
skip.
at line-selection.
check cursor(9) eq 'T_OBJETOS'.
set parameter id 'MON' field sy-lisel+1(10).
call transaction 'SMOD' and skip first screen.
*---------------------------------------------------------------------*
* FORM build_tree *
*---------------------------------------------------------------------*
* ........ *
*---------------------------------------------------------------------*
form build_tree.
call function 'RS_TREE_CONSTRUCT'
TABLES
nodetab = mylist
EXCEPTIONS
tree_failure = 1.
endform. "build_tree
*---------------------------------------------------------------------*
* FORM draw_tree *
*---------------------------------------------------------------------*
* ........ *
*---------------------------------------------------------------------*
form draw_tree.
sy-lsind = 0.
call function 'RS_TREE_LIST_DISPLAY'
EXPORTING
callback_program = 'Z_BUSCA_EXIT'
callback_user_command = 'USER_COMMAND' "'NODE_SELECT'
IMPORTING
f15 = f15.
endform. "draw_tree
*&---------------------------------------------------------------------*
*& Form monta_tabela
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
* --> p1 text
*