Book Image

Mastering SAP ABAP

By : Paweł Grześkowiak, Wojciech Ciesielski, Wojciech Ćwik
Book Image

Mastering SAP ABAP

By: Paweł Grześkowiak, Wojciech Ciesielski, Wojciech Ćwik

Overview of this book

Advanced Business Application Programming (ABAP) is an established and complex programming language in the IT industry. This book is designed to help you use the latest ABAP techniques and apply legacy constructions using practical examples. You'll start with a quick refresher on language and database concepts, followed by agile techniques for adding custom code to a modern ABAP system. After this, you will get up to speed with the complete ABAP toolset for importing data to and from different environments. Next, you'll learn how to print forms and work with the different ABAP tools for Extensible Markup Language (XML) manipulation. While covering further chapters, you'll gain insights into building stunning UI5 interfaces, in addition to learning how to develop simple apps using the Business Object Processing Framework (BOPF). You will also pick up the technique of handling exceptions and performing testing in ABAP. In the concluding chapters, you can look forward to grasping various techniques for optimizing the performance of programs using a variety of performance analysis tools. By the end of this book, you will have the expertise you need to confidently build maintainable programs in Systems, Applications, and Products (SAP).
Table of Contents (25 chapters)
Title Page
Copyright and Credits
Dedication
About Packt
Contributors
Preface
Index

Additional tutorials


This part contains additional tutorials that can help the reader to learn and work with the system. These tutorials lead the reader through the creation of functionality, step by step.

Creating a report from the template

This tutorial shows how to create a report from a template. The following steps will guide the reader through the creation process:

  1. Go to ABAP Workbench (transaction SE80), choose Program from the development object list, and choose a name. We've used ZMSA_R_CHAPTER0_0:
  1. You will be asked whatever you want to create new object. Click Yes on the popups that will appear:
  1. Give a program name and click the green check mark on the popups that will appear:
  1.  Add the following code into the editor window and activate reporting:
CLASS lcl_demo DEFINITION CREATE PRIVATE.
  PUBLIC SECTION.
    CLASS-METHODS main.

  PRIVATE SECTION.
ENDCLASS.

CLASS lcl_demo IMPLEMENTATION.
  METHOD main. 
  ENDMETHOD.

ENDCLASS.
START-OF-SELECTION.
lcl_demo=>main( ).

Uploading graphics to SE78

The SAP system allows you to upload images. This is a useful functionality used for many purposes (such as SmartForms). The following is a tutorial that shows how to add a picture to the SAP system:

  1. Go to Administration of Form Graphics (transaction SE78). Choose the BMP folder from the tree on the left-hand panel and enter a new image name:
  1. Choose Import from the Graphic menu:
  1. In the popup, fill in the Description and enter the path in the File name field of the image file:
  1. After clicking the green check mark, the image will be uploaded to the server.

At the time of writing, you can use the ZLOGO image in all forms and in all transactions that require it.