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

Custom Function Module for the New Process Codes

Former Member
0 Likes
2,135

I want to distribute the custom table data . For that i have written the program using MASTER_IDOC_DISTRIBUTE. I have created the custom message & idoc types along with their assignments.

I got struck up at the process code. I have to assign the function module for that process code. Can anyone kindly help me in writting the code at that function module ?

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,811

go to tcode we42

15 REPLIES 15
Read only

Former Member
0 Likes
1,812

go to tcode we42

Read only

0 Likes
1,811

hi,

i think you need the process code for outbound idoc ? then you have to use tcode WE41 and maintain this one in the partnerprofile outbound settings at tcode WE20

Read only

0 Likes
1,811

i can create the process code. But i want the code for writing in the function module that need to assign to this process code.

Read only

0 Likes
1,811

?

You don´t have to assign the process code in the fm.

You have to assign this code in the tcode: WE20 for your Outbound IDoc.

Regards,

Gordon

Read only

0 Likes
1,811

you have to run the report to send outbound idocs and assign message type in WE20 to a logical system and also in BD64..

cheers

Read only

0 Likes
1,811

Hi Friends,

My requirement is , i need to transfer the table records. For that i have created the Message/Idoc Types and also created the Partner profile and the Distribution model view .....all alll i have done.

My doubt is , in the we20, at the outbound parameters , i can give the Message/Idoc types that i have created. Ok thats fine

But at the inbound parameters, i have to give the inbound process code. So i have created the Inbound process code. As we know that for every process code a function module is attached, now i have to create the function module which posts the records in receiver side.

so 1. Does the Function module need to be RFC Enabled ?

2. Do we need to create Object type in SWO1 once i

create and release the function module ?

Read only

0 Likes
1,811

Hi,

You are transfering the content from 1 client to other client, for tranferrring the content to idoc you need to write a function module and that function module needs to be in the sender system.

Then the receiver system will receive that idoc and that idoc has to be processed so the inbound function module what ever you write should in the receiver system and that doesn't be an RFC enabled function module.

I hope I am clear.

Thanks,

Mahesh.

Read only

0 Likes
1,811

How about the code in that Function Module ?

Read only

0 Likes
1,811

Hi,

The code in the inbound function module should be written in such a way that, you need to read the data from the idoc first and then post the data into the database table, if you have any custom transaction for that or directly use the insert statement for inserting the entries into that custom table.

First of all you need to have that custom idoc type in the receiver system as well.

Thanks,

Mahesh.

Read only

0 Likes
1,811

OK. I have written the code. Now in WE42, while creating the Process code, in the Function module drop down box, the function module that i have created is not there !!!

Read only

0 Likes
1,811

Hi,

Once you are done with the inbound function module in the receiver system, then you need use WE57 transaction for giving your function module and the idoc type and message type combination there.

After that use BD51 transaction for defining the settings for your function module.

After doing the above 2 steps then only you can see your function module name in the drop down list of the WE42 transaction.

Thanks,

Mahesh.

Read only

0 Likes
1,811

Thanks mahesh. I solved that Problem.

Now i am testing all the Z*types and the Program.

I have rewarded you the points.

Read only

0 Likes
1,811

HI Mahesh,

I have created the Outbound IDocs using MASTER_IDOC_DISTRIBUTE. But the status is in Yellow ? Why ? What should i do ?

Read only

0 Likes
1,811

Hi Manjunath,

In the partner profile (WE20)for that partner and message, the triggering mode is selected as Collect IDOC's I guess, change that to Trigger Immediately and they will be processed as soon as the IDOC's are created.

Thanks,

Mahesh.

Read only

0 Likes
1,811

No Mahesh, i have used the option of 'Trigger Immediately'.