Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Passing table parameters via RFC using VBA / VB.NET

Hi,

I try to invoke an official SAP RFC, which has optional table parameters. When I do the coding in VB.NET, the connection is established properly. Yet the call to send data using the table parameter fails.

ST22 dump analysis shows the following error: <b>"Invalid Delta Manager object ID (20 <=> 14)"</b>.

Error analysis section states: <i>"Internal error with RFC (Remote Function Call). An object was supposed to be registered in the Delta Manager, but the proposed object number 20 has already been used."</i>

Does it have something to do with passing tables as parameters? Because the function is called successfully when I don't specify tables.

Here's the relevant bit of my VB.NET code:

'--- start of code

'... after establishing the connection

        'Academics-related RFC function
        theFunc = functionCtrl.Add("HRIQ_STUDENT_STUDIES_DT_RFC")

        Dim oTableFactoryCtrl As Object
        Dim oTable As Object
        oTableFactoryCtrl = CreateObject("SAP.TableFactory.1")

        oTable = oTableFactoryCtrl.NewTable()
        oTable.CreateFromR3Repository(sapConnection, "PIQRFCAGD_DATES", "ANTICIP_GRADUATION")

        theFunc.Tables.Add(oTable)

        oTable.AppendRow()
        oTable.Value(1, "ANTICIPATEYEAR") = "2007"
        oTable.Value(1, "ANTICIPATEPERIOD") = "1"
        oTable.Value(1, "PROGRAM_OBJECTID") = "50000782"

        Dim returnFunc As Boolean
        returnFunc = theFunc.Call

'--- end of code

"ANTICIP_GRADUATION" is the name of the table parameter while "PIQRFCAGD_DATES" is the underlying type of this table.

Anyone encountered this error?

Janek

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question