Application Development 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: 

how to pass data to .net through RFC

Former Member
0 Kudos
212

hello friends,

I have to pass data to .net through RFC, wat exactly i need to do for this.

suppose i want to pass all the details abt material.

i have wriiten the select statements to get the data in my table, how do i transfer this to .net

3 REPLIES 3

Former Member
0 Kudos
92

Hi,

use this component in between the .net and sap.

SAP.BAPI.CON.

it will connect the two systems for passing data.

if it is helpful, please reward points.

regards,

satish.

0 Kudos
92

can u pls elaborate your answer

Former Member
0 Kudos
92

Hi Amit,

You have to define table params in ur BAPI.

try this example in VB.NET:

Imports SAPBAPIControlLib //sap library

Imports SAPTableFactoryCtrl

Dim bapi As Object

Dim connection As Object

Dim FLDSTAB As Table

Dim DATATAB As Table

Dim OPTTAB As Table

bapi = CreateObject("SAP.Functions")

connection = bapi.Connection

RfcReadData = bapi.add("RFC_READ_TABLE")

FLDSTAB = RfcReadData.tables("FIELDS")

OPTTAB = RfcReadData.TABLES("OPTIONS")

DATATAB = RfcReadData.tables("DATA")

'RFC_READ_TABLE" is a standard function to read any table data from sap to remote applications like vb / vb.net.

'FIELDS,OPTIONS,DATA" are the table parameters for the above function.you can extract the data from these table parameters by declaring table objects in .net

reply for further information.

Reward points if helpful

Regards,

kishore