Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

calling a method

Former Member
0 Likes
499

Hi,

How to call a method in reports ?

thanks in advance.

kaladhar

4 REPLIES 4
Read only

Former Member
0 Likes
483

Hi,

Using

call method <method name>

ex: CALL METHOD team_red->execution.

Regards,

Narasimha

Read only

0 Likes
483

Hi,

Use the button "pattern" --> CALL METHOD.

To call a static method of a class you can directly use the class_name=>method_name ()

but for non static methods, first you will have to create an instance of the class and using that instance in the pattern you can call the method.

regards,

Advait

Read only

Former Member
0 Likes
483

uh ähm, making use of the statement "Call Method"

but to make it easier for you got in SE80 the button Pattern.

then check the abap objects pattern.

rest is kinda intuitive.

Read only

Former Member
0 Likes
483

Hi,

SAP ABAP SYNTAX FOR CALL METHOD of an external object

Basic form

CALL METHOD OF obj m.

Additions

1. ... = f

2. ... EXPORTING p1 = f1 ... pn = fn

3. ... NO FLUSH

Effect

Calls the method m of the object obj . m can be a literal or a variable.

CALL METHOD

Addition 1

... = f

Effect

Stores the return value of the method in the variable f . The return value can also be of type OLE2_OBJECT . This addition must always come before other additions.

Addition 2

... EXPORTING p1 = f1 ... pn = fn

Effect

EXPORTING passes values of fields to the parameters of the method. p1 , p2 , ... are either key word parameters or position parameters. If assignment of parameters is by sequence, p1 , p2 , ... must begin with "#", followed by the position number of the parameter. At present, only position parameters are supported. The export parameters always come at the end of the statement.

Addition 3

... NO FLUSH

Open an EXCEL file with the method 'Open'.

Reward If helpfull,

Naresh.