How to debug a popup screen in ABAP?


Methods to debug a Popup screen in ABAP debugger.

It is always difficult to debug a popup screen in SAP ABAP.

To debug a Popup screen, we need to create a system file that could generate a system command to allow debugging for the Popup screen.

There are three different methods that could allow to debug a Popup screen.

The best way is to create a shortcut file from the SAP screen. Click icon in the SAP toolbar.
It shows a screen to create shortcut for the debugging.





Enter the title as "Debugger".
Choose "System Command" as type and enter "/h" in the command.
Enter your system details where you want to debug. Here i am going to debug the production system, so i have entered the system id as K9P.

Click "Finish" and you could see a short cut in your desktop with *.sap extension.

Now drag the debug.sap file to the popup screen that you need to debug.




This will make the popup screen enter into debugging mode. Proceed from here with your debugging skills to debug.

But still, there are other two methods to create the shortcut debug file for Popup screen debug.

Option 2
You can create a shortcut from your desktop using Windows shortcut creating functionality.
Right click in your desktop and select "New-> SAP GUI Shortcut".


Name it as "debug.sap".
Right click on the shortcut icon and click edit and proceed as above to create a shortcut.



Option 3

You can also create a debugging file from notepad. But this is a worst case method where you are not able to create a shortcut from SAP.

Open your notepad and enter the following.


[ F u n c t i o n ]
C o m m a n d = / H
T i t l e = D e b u g g e r
T y p e = S y s t e m C o m m a n d

Save it as "debug.sap".

Drag and drop on the popup screen you want to debug.


For more Tutorials, visit ABAP Tutorials, Tips & Tricks and Certification Questions

Steps to copy or rename existing programs in SAP

Copy an existing program in SAP


To Copy an existing program in SAP, follow the below steps.

1. Go to SE38
2. Enter the program that you need to copy.
3. Press the copy button in the toolbar or press CTRL+F5.

Screen shot to explain copying in ABAP editor


In the popup screen, enter the target program name. This copies the source program to target program.

Pop up to name the target program for copy in ABAP Editor
Once done, you get an another popup screen for the elements to be copied. Select the elements according to your requirement that is shown in the below screen shot.

Press Copy and the source program is copied to the target program with the program elements you selected.


Renaming an existing program 


To Rename an existing program in SAP, follow the below steps.

1. Go to SE38
2. Enter the program that you need to rename.
3. Press the rename button in the toolbar or press CTRL+F6.


It is same as explained above for the copying.


Here all the program elements are transferred to the target program.
Includes are not renamed but you could select it to rename the includes in the program.



For more Tutorials, visit ABAP Tutorials, Tips & Tricks and Certification Questions