ABAP Developer use DEFINE … ENF-OF-DEFINITION to create local macro in ABAP Code. Macro definitely help developer to create code more readable and to avoid code repetition.

In this article, we would explain how to create global macro, Global Macro can be created by maintaining entries in TRMAC table.

how-to-create-global-macro

You can create global macro with maintain TRMAC table via SM30 Transaction code.

how-to-create-global-macro-2

Please entered Name of Your macro, First Line value is 000 , if your macro multiple line you just increment this value. Macro Text is your ABAP Code. You can see whole TAMBAH macro on this picture.

how-to-create-global-macro-3

Go to SE38 and create ABAP Program to call that macro.

The Result :

how-to-create-global-macro-4

Incoming search terms:

Leave a Reply

Your email address will not be published. Required fields are marked *