Show TOC

Background documentationSwitching Directly to the ABAP Debugger While Executing a Program Locate this document in the navigation structure

 

While executing:

  • Programs that have classic Dynpro interfaces

  • Running processes, for example, background jobs

you can now switch directly to the ABAP Debugger at any time and control the execution using its tools. Follow the procedure below:

Programs with Classic Dynpro Interfaces

With programs that have a classic Dynpro interface you can communicate using the active window of the SAP GUI. Everytime a user action is possible you can activate the ABAP Debugger with special commands immediately. Follow the procedure below:

SAP GUI window

In the main window of an application you can enter the following commands in the command field of the system function bar. You can also select relevant options in the menu bar:

The System Function Bar

Menu bar

Effect

/h

  System   Utilities   Debugging Dynpro  

The program is stopped at the first statement in the currentl Dynpro processing.

/ha

  System   Utilities   Debugging ABAP  

Dynpro processing is skipped. The program is stopped at the first ABAP statement.

/hs

  System   Utilities   Debugging System  

System debugging is activated.

Dialog Window of SAP GUI

The system function bar and menu bar are not available in dialog windows. However, using SAP GUI for Windows you can implement GUI connections. Follow the procedure below:

  1. Define a standard GUI connection. Specify the following parameters:

    Type: System Command

    Command: /h ( /hs, /ha)

  2. Use drag and drop to drag the GUI connection to the active dialog window.

For the next user action, for example, confirming with the enter key, the program is stopped and the ABAP Debugger is started.

Note Note

In the following debugging session, the control of the application can be transferred at any time with the command /h (/hs, /ha) to the Debugger, even if the Debugger was already started.

End of the note.
Running Processes/Background Jobs and Waiting Rolled-Out Main Modes

In the ABAP Workbench you can activate the debugging for running processes (in particular for background jobs) and for waiting, rolled-out main modes.

Proceed as follows for running processes:

  1. Background Jobs: Determine which application server of the AS ABAP the background job is running on and in which process. You can use the job overview transaction (SM37) for this.

  2. In the process overview (SM50) of the application server, select the process and choose   Administration   Program   Debugging  .

The executed is interrupted at the next interruptable statement that is processed.

Note Note

Interruptable statements are:

  • Calling a procedure (method, function module, ...)

  • a LOOP statement

  • a SELECT statement

End of the note.

Proceed as follows for waiting, rolled-out main modes:

  1. Start user list transaction (SM04).

  2. With a double-click, select the user whose main made you want to debug.

  3. A dialog box appears. Select the main mode to be checked and then Inspect Mode.

The window of the ABAP Debugger appears and you can inspect the rolled-out main mode. In this way it is not possible to proceed with the execution of the process in the Debugger. The related functions are hidden.