RetStack function

Returns an @fm delimited list of the currently executing procedures as seen in the debugger's Call Stack window.

stack = RetStack()

None.

After the call, stack contains the call stack, as a field mark delimited variable.

Return Stack in Event Code:

/* the current procedure will be at the top of the list in List<1>.  The procedure that calls it is next, in List<2>

*/

 

declare function RetStack

List = RetStack()

CurrentProc = List<1>

CallingProc = List<2>

If this code is run from the window OIPI_PLAY, in application EXAMPLES, from the button BTN_RETSTACK, the return stack will be:

List<1> =  $$$EXAMPLES*CLICK*OIPI_PLAY*BTN_RETSTACK
List<2> =  RUN_EVENT

Return Stack in Stored Procedure:

/*  running the same code in a stored procedure called STARTPROC,
called from BUTTON_1 in the window OIPI_PLAY in the EXAMPLES application, the return stack is as follows:

List<1> = STARTPROC

List<2> = $$$EXAMPLES*CLICK*OIPI_PLAY*BUTTON_1

List<3> = RUN_EVENT
*/
  • guides/programming/programmers_reference_manual/retstack.txt
  • Last modified: 2024/06/19 20:20
  • by 127.0.0.1