cancel
Showing results for 
Search instead for 
Did you mean: 

Insert the data in sap tables from C SHARP application

Former Member
0 Kudos

Hi All,

I want to save some data in sap table from my CSharp(DOTNET) windows application.I tried with the help of SAP.Net Connector but that connector is not been supported visual studio 2005 or i not have visual studio 2003 .Soo plz any one can help how i can do this .

If any one have a idea then plz give me some example also how we did.

thanks

regards

sandeep Dabral

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi All,

I also wish to push data into SAP System through BAPI_SALESORDER_CREATEFROMDAT2.

I am using MS VS 2003 and SAP .Net Connector 1.0.

How can we write code which will insert data from web applicaion to SAP system

Or simply creating Sales order from Web Application.

Thanks

Sunil Pawar

Edited by: Sunil Pawar on Nov 28, 2008 9:57 AM

Are there any updates

Former Member
0 Kudos

actually the best solution is to write a ABAP RFC in your SAP to add datas into your SAP Table if a BAPI or standard RFC isn't available in your SAP system.

Your ABAP looks like this.... (SE37)

tables znewsletter.
data wa type znewsletter.
wa-newsletter_name = 'JeromeDim'.
wa-newsletter_email = '123@email'.
wa-newsletter_comp = 'SAPCONSULTING'.
insert into znewsletter values wa.
write 'ajout fait'.

and With VS2003 you create your library DLL with the SAP.net connector

and With VS2005/2008 you add your DLL in your reference folder....

an other solution is to expose your RFC with the SAP WEBAS and the service SOAP/RFC as a SAP Webservice.

Former Member
0 Kudos

Hii Friends ,

I have a rfc or bapi in abap i want to insert the data in sap table from C Sharp application .How we can do this without SAP.Net Connector, i have visual studio 2005 and i think that connector not supported and i don't have 2003 visual studio .Can u explain with the example how we can do this .

thanx

regards

sandeep dabral

Former Member
0 Kudos

without you cant or only if you use the dcom connector ....

An other way is to use an external toolbox as erp connect [http://www.theobald-software.com/cms/en/erpconnect.net/erpconnect.net-sap-und-.net-nahtlos-verb.html|http://www.theobald-software.com/cms/en/erpconnect.net/erpconnect.net-sap-und-.net-nahtlos-verb.html]

Dorian
Participant
0 Kudos

Sandeep:

If your SAP system is fairly recent (6.20 or later) the best solution is to use web services.

I was in the same spot that you are - trying to use the .Net Connector with VS2005. I ended up rewriting my C-Sharp code to communicate via web services instead of RFC.

The changes to the code on the C-Sharp side are not really a major deal, and the performance overhead with SOAP is not excessive compared with RFC calls - at least not with the data volumes I'm using.

There is lots of documentation on how to do this in this forum, plus in the blogs section.

Regards,

D.

Former Member
0 Kudos

You have to use SAP .NET connetor to make interface with SAP. This is better way of doing interface between .NET and SAP.

You create web service (wsdl) in .NET 2003 and try to use that in .NET 2005.

Regards,

Govind.

Former Member
0 Kudos

RFC proxy is alway safer and faster than web services.....

Dorian
Participant
0 Kudos

You have to use SAP .NET connetor to make interface with SAP. This is better way of doing interface between .NET and SAP.

You create web service (wsdl) in .NET 2003 and try to use that in .NET 2005.

You're getting the two technologies confused ......

.Net Connector is used for RFC-type interfaces. It calls Bapi's directly. Web services are not involved for this type of interface.

WSDL files are used to generate proxies for the .Net client to call Web Services (typically web-enabled Bapi's). This type of interface uses SOAP protocol not RFC and does not use the .Net Connector. Enterprise Web Services may be discovered using the .Net Enterprise Service Explorer, which is a different component from the .Net Connector.

Regards,

D.

Dorian
Participant
0 Kudos

RFC proxy is alway safer and faster than web services.....

Yes, that is correct. However, Sandeep stated that he does not have VS2003 available:

I have a rfc or bapi in abap i want to insert the data in sap table from C Sharp application .How we can do this without SAP.Net Connector, i have visual studio 2005 and i think that connector not supported and i don't have 2003 visual studio .Can u explain with the example how we can do this .

Therefore the .Net Connector for RFC interfaces is not an option.

D.

Former Member
0 Kudos

confused ? All integration projects are confused. ;-)....

I did it as I said (VS2003 + .net connector to develop webservice on IIS and VS2005 which uses theses webservices) and that makes sens....