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_customer_list

Former Member
0 Likes
657

I am fairly new to data transfer with sap.

I am trying to write app to export list of customer from sap using bapi_customer.getlist. Below is my test code but I am getting o rows back. Can anyone help.

Thanks

AppSapConfig sapCfg = new AppSapConfig();

RfcDestinationManager.RegisterDestinationConfiguration(sapCfg);

RfcDestination sb = RfcDestinationManager.GetDestination("XXX");

try{

RfcRepository repo = sb.Repository;

IRfcFunction companyBapi = repo.CreateFunction("BAPI_CUSTOMER_GETLIST");

companyBapi.SetValue("Maxrows", "0");

companyBapi.SetValue("Cpdonly", "");

companyBapi.Invoke(sb);

IRfcTable detail = companyBapi.GetTable("AddressData");

for (int ii = 0; ii < detail.Count; ii++)

{

Console.WriteLine("????");

}

4 REPLIES 4
Read only

madhu_vadlamani
Active Contributor
0 Likes
618

Hi,

Please pass some number in Maxrows ,id range parameters and see.Then check in Addressdata and Special data.

Regards,

Madhu.

Read only

0 Likes
618

Thanks

madhurao123

However would you have some sample code I work with? I am very visual?

Thanks in advance

kevlangdo

Read only

0 Likes
618

Hi Kelvan,

There are some good no of threads available please check.

[Calling Bapi |https://websmp209.sap-ag.de/~sapdownload/011000358700007640702002E/SAPJCo.pdf]

Regards,

Madhu.

Read only

0 Likes
618

Sorry I don't have access to the marketplace. Only a few people at our company have this access and I am not one of them.

Thanks