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

Help in Creation of a Function Module.

Former Member
0 Likes
560

Hi Abapers,

I am new to ABAP and hardly have knowledge abt it. I need to create a Function Module which is of the type RFC. Pls provide me information and steps to create the same.

Many thanks in Advance.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
515

Hi Pooja,

For the creation of Function Module , pls follow the below steps.

You can create function module by using transaction code se37, but before that you need to create a function group. se37>goto>function group>create and activate. Then create the fucnction module. give import parameters (passed from program) and export parameters (passed from FM to Program).

You can pass values by using tables also. Write your code in FM. Thats it.... Your FM is ready. Just call it from your program..

the below links.. also .. provides a lot of info..

http://www.saptechnical.com/Tutorials/ABAP/FunctionModule/page1.htm

http://help.sap.com/saphelp_47x200/helpdata/en/22/0425f2488911d189490000e829fbbd/frameset.htm

Pls reward if useful.

Thanks,

Sirisha,

Hi Abapers,

I am new to ABAP and hardly have knowledge abt it. I need to create a Function Module which is of the type RFC. Pls provide me information and steps to create the same.

Many thanks in Advance.

2 REPLIES 2
Read only

Former Member
0 Likes
516

Hi Pooja,

For the creation of Function Module , pls follow the below steps.

You can create function module by using transaction code se37, but before that you need to create a function group. se37>goto>function group>create and activate. Then create the fucnction module. give import parameters (passed from program) and export parameters (passed from FM to Program).

You can pass values by using tables also. Write your code in FM. Thats it.... Your FM is ready. Just call it from your program..

the below links.. also .. provides a lot of info..

http://www.saptechnical.com/Tutorials/ABAP/FunctionModule/page1.htm

http://help.sap.com/saphelp_47x200/helpdata/en/22/0425f2488911d189490000e829fbbd/frameset.htm

Pls reward if useful.

Thanks,

Sirisha,

Read only

Former Member
0 Likes
515

Hi Pooja,

Please follow the below steps to create a function module :

1. Goto Transaction code : SE37.

2. Create a Function Group first.

a) From the Menu Bar Choose Goto -> Function groups -> Create group.

b) Specify the function group name and a short text.

c) Choose Save.

When you create a new function group, the system automatically creates a main program containing two includes. Like any other programs and includes, you can display them in the Repository Browser.

3. Now create a Function Module.

4. Enter the function's name in the field Function module.

5. Choose Create.

6. In the Enter function group dialog box, enter the function group to which you want to assign the function module.

7. In The Attributes Tab select Remote Enabled Module (since you want a RFC function module ).

8. Give the Import and Export parameters and exceptions(if any).

9. Write the functioning part of the fuction module in the Source code tab.

10. Save and Activate your function Module.

Now go ahead and use your function module where ever you want.

Hope it helps.

Reward if helpful.

Regards

Hemant Khemani