What is the difference between macro and subroutine?
Answer Posted / paramjeet
Macros can only be used in the program the are defined in
and only after the definition are expanded at compilation /
generation. Subroutines (FORM) can be called from both the
program the are defined in and other programs . A MACRO is
more or less an abbreviation for some lines of code that are
used more than once or twice. A FORM is a local subroutine
(which can be called external). A FUNCTION is (more or less)
a subroutine that is called external. Since debugging a
MACRO is not really possible, prevent the use of them (I?ve
never used them, but seen them in action). If the subroutine
is used only local (called internal) use a FORM. If the
subroutine is called external (used by more than one
program) use a FUNCTION.
| Is This Answer Correct ? | 61 Yes | 36 No |
Post New Answer View All Answers
Can we include customizing include or an append structure with pooled or cluster tables? : abap data dictionary
ABAP : Classical reports events name
What are the problems in processing batch input sessions? How is batch inputprocess different from processing online?
What are the uses of the information in the data dictionary? : abap data dictionary
What is the process to enhance the Infotype
What is maintenance view?
dynamic programming in sap abap
What is the difference between table and template?
What is check table?
Did you create any joins?
Explain how to create any functions? How to go about it?
Difference between /N and /BEND?
How do you save data in bdc tables? : abap bdc
What was the requirement of IDoc in your project? How it was working?
In sap script how to print bar code in vertical manner