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

Hardcode Partner Function

Former Member
0 Likes
635

HI

is it possible to Hard-Code PARTNER FUNCTION , while processing the Sales Order in CRMD_ORDER Tcode.

Ex: while saving the Sales Order in CRMD_ORDER , I want to add new Partner Function in Partner TAB.

Can I have sample code , how do that.

Highly Appreciated your Help.

5 REPLIES 5
Read only

Sm1tje
Active Contributor
0 Likes
600

For this you can use BaDI ORDER_SAVE with method CHANGE_BEFORE_UPDATE. In the BaDI implementation you must use function module CRM_ORDER_MAINTAIN to add partner function. I don't have any sample code, but what you can do is this:

Set a break-point at FM CRM_ORDER_MAINTAIN. Now create/change a sales order and save it. Enter exactly the data that you want to set for the partner function. Now upon saving the data, you will hit the break point. Now look at the parameters and check what and how parameters have to be set for maintaining the partner function.

P.S. It seems you want to solve this with programming. However, have you already spoken a functional consultant. It might even be possible to set this partner function via customizing.

Read only

Former Member
0 Likes
600

Hi

thanks.

But my requirement is while Processing the Sales Order, I want to HARD CODE partner Function.

Ex: If product = 'ABC'.

Now I want to add one Partner Function In CRMD_ORDER Partner tab.

ex: Shipper(Description) 1000002 (Partner Number).

Read only

Sm1tje
Active Contributor
0 Likes
600

Yeah, you can do the HARD CODING in your BaDI implementation.

Read only

Former Member
0 Likes
600

Thank you.

But May I knw how to do.

Read only

Sm1tje
Active Contributor
0 Likes
600

Look at my first reply. Create BaDI implementation for ORDER_SAVE BaDI and call function module CRM_ORDER_MAINTAIN to set the partner function.

P.S. Do not post several threads on the same issue. Moderators will give you a slap on the wrist.