‎2020 Jun 18 4:03 AM
Hi!
I have some trouble in method with parameter. I did follow https://help.sap.com/doc/abapdocu_752_index_htm/7.52/en-us/abapmethods_parameters.htm And this is was my code :
....
PUBLIC SECTION.
INTERFACES if_oo_adt_classrun.
METHODS loop.
IMPORTING num type i.
...
got error on importing says " This Statement IMPORTING is unexpected ". I using Abap Class instead of Abap Program.
Thank you for your time.
‎2020 Jun 18 5:35 AM
"METHODS loop IMPORTING num type i." is one 'statement', otherwise you will have 'statement' 'METHODS loop.' which is ok for a method without parameters, but than you would have 'IMPORTING num type i.' which cannot be interpreted. (you can have the method name and its parameters in different lines, just dont separate them with a dot.)
"....
PUBLIC SECTION.
INTERFACES if_oo_adt_classrun.
METHODS loop IMPORTING num type i.
"....
‎2020 Jun 18 4:05 AM
‎2020 Jun 18 4:08 AM
‎2020 Jun 19 7:49 AM
‎2020 Jun 18 5:35 AM
"METHODS loop IMPORTING num type i." is one 'statement', otherwise you will have 'statement' 'METHODS loop.' which is ok for a method without parameters, but than you would have 'IMPORTING num type i.' which cannot be interpreted. (you can have the method name and its parameters in different lines, just dont separate them with a dot.)
"....
PUBLIC SECTION.
INTERFACES if_oo_adt_classrun.
METHODS loop IMPORTING num type i.
"....
‎2020 Jun 19 7:49 AM