Global interface with example using parameters.
* Interface is the collection of methods which are defined & not implemented.
* In interface all methods are public by default.
* In interface all methods are abstract methods.
Steps to create global interface in SE24.
1. Goto T-code SE24.
2. Give name and click on create, select interface and press enter.
3. Give description, Press enter.
4. Give method name, level, description.
6. Click on parameters and give parameters.
7. Save and activate and go back.
8. Create a sub class.
* Goto T-code SE24.
* Give name, Press enter, select class and press enter.
* Give description and press enter.
* Goto methods double click on method and write logic.
METHOD zab_if_sale_delivery~display.
SELECT SINGLE erzeterdat
vbtyp
ernam
FROM vbak
INTO ( perzet,perdat, pvbtyp, pernam )
WHERE vbeln EQ pvbeln.
ENDMETHOD.
* Check and activate.
* Execute.
* Input
* Click on edit interface view.
* Output
* Repeat step 8.
* Write logic.
METHOD zab_if_sale_delivery~display.
SELECT SINGLE erzeterdat
vbtyp
ernam
FROM likp
INTO ( perzet,perdat, pvbtyp, pernam )
WHERE vbeln EQ pvbeln.
ENDMETHOD.
* Input
Comments
Post a Comment