cancel
Showing results for 
Search instead for 
Did you mean: 

How to add parameter data into .NET RFC call

Former Member
0 Kudos

I'm using SAP.NET connector 2.0, i want to add some test data into a SAP structure which has imported into my project though a BAPI.

How do I get data into these structures and how do I then call the RFC?

I have the connection set up correctly and everything cept I don't know what to add where.

heres the code so far:

sapProxy11.Bapi_Customer_Createfromdata1(??what format do these parameters which are structures need to be in??)

thanks in advance

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

check the following link...

http://www.sap.com/partners/icc/scenarios/pdf/ICC_INTEGRATION_GUIDE_22.pdf

reward me points..

Shyja

Former Member
0 Kudos

Not really what I was looking for, I already have all this information. I am looking for a more technical example.

Former Member
0 Kudos

Hi Jim,

After you have referenced your bapi you can use it like;


SAPProxy1 proxy = new SAPProxy1();
BAPIKNA106 companyData = new BAPIKNA106();
companyData.BUILDING = "test";
companyData.CITY = "cityTest";
			
proxy.BAPI_CUSTOMER_CREATEFROMDATA1(companyData, "X", .., .., .., .., ..,

As you have seen that, bapi needs its own tables. for company data I have showed how to create this table. other tables that bapi need, you can create as I did.

Another important thing is this bapi return two variables first CUSTOMERNO, second RETURN. You have to pass these return variables as passing out parameters as;


string customerNo;
BAPIRETURN1 ret = new BAPIRETURN1();
proxy.BAPI_CUSTOMER_CREATEFROMDATA1(.., ..,..,..,.., out customerNo, out ret) // look the last two parameters...

Best Regards,

Huseyin Akturk

SW Engineer & SAP ABAP Consultant

www.huseyinakturk.net

ps : don't forget to give points if helpful

Answers (0)