Skip to Content
0
Former Member
Oct 06, 2008 at 11:25 AM

Get the value of a field dynamically using system_callstack

3567 Views

Hi Gurus...

My requirement is to get the value of a field used in a program which is available in my call stack while debugging.

I am using FM system_callstack but it just gives an internal table comprising of 3 fields programname, event type and event name.

I do not know how to retrieve the value of a variable being used in one of the programs.

My sample code is

CALL FUNCTION 'SYSTEM_CALLSTACK'

IMPORTING

et_callstack = l_cstack_tab. " internal table

READ TABLE l_cstack_tab INTO l_cstack_wa INDEX 4.

IF sy-subrc = 0 AND l_cstack_wa-progname IS NOT INITIAL.

l_evt_class = l_cstack_wa-progname.

  • then what shud I do.*********************

ENDIF.

Please help.