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

BAPI for vendor creation

Former Member
0 Likes
3,823

Hi experts,

          Tired of searching for BAPI for vendor creation. BAPI_VENDOR_CREATE is the right bapi, but it calls XK01 tcode nothing else. i need to create vendor from third party tool using JCo. Also tried with VENDOR_INSERT, it directly updates data to the table and not RFC, so its not advisable. Please let me know if there is any solution.

Thanks in Advance

6 REPLIES 6
Read only

Former Member
0 Likes
3,128


HI Remya,

Use Idoc CREMAS05 for vendor creation. Populate the segments with required data and post the inbound idoc through middleware.

Regards,

Lokeswari

Read only

JarosBaw
Active Participant
0 Likes
3,128

Hi,

You can use class VMD_EI_API. You can find many about it in SCN.

If You want call it from outer system You should create your own remote-enabled 'Z' function module which will fill parameters and execute this class methods..

Regards,

Jarek

Read only

Former Member
0 Likes
3,128

Hi Remya,

create a Z RFC function module and call the function module VENDOR_INSERT inside that by passing the values.

Read only

0 Likes
3,128

Please check this http://scn.sap.com/thread/392066

It directly updates 3 tables. So its not advisable...

Read only

Former Member
0 Likes
3,128

Hi,

As seen above, the best solution is to use class VMD_EI_API. check it in se24

I used it to create vendors and it works wonderfully.

This really acts like a BAPI.

If I remember well, you have to initialize the vendor with method INITIALIZE.

Fill your structure IS_MASTER_DATA, it contains every data you need to update.

HEADER Types VMDS_EI_HEADER

=> Contains the vendor number

CENTRAL_DATA Types VMDS_EI_CENTRAL_DATA

=> Contains most of the vendor data (LFA1)

COMPANY_DATA Types VMDS_EI_VMD_COMPANY

= > Contains most of the company data (LFB1)

PURCHASING_DATA Types VMDS_EI_VMD_PURCHASING

=> Contains most of the purchasing organization data (LFM1)

If you use specific fields, you simply need to had it to the includes.

Then call method MAINTAIN_BAPI with them.

Please check this question as answered if you think it is, else I would answer to your questions.

When I tried to find something on this subject I couldn't find anything usefull except this class name in the middle of nowhere, so I hope my search would help someone

Read only

0 Likes
3,128

I really appreciate your help... thank you all..