cancel
Showing results for 
Search instead for 
Did you mean: 

how to pass out parameter that has a structure

Former Member
0 Kudos

Hi All,

I'm creating an RFC server project and am just trying to define the "out" parameter correctly, yet keep getting the message "<i>Identifier expected</i>" or "<i>The out parameter 'myReturn' must be assigned to before control leaves the current method</i>" (based on if I predefine the variable or not). My question - what am I doing wrong in my code (see below)?? Note I'm using a common BAPI below instead of my custom RFC so people can duplicate the problem as i'm getting the same message as with my custom RFC. Thanks.

BAPIRET1 myReturn = new BAPIRET1();

protected override void Bapi_Customer_Display (

string myCustNum,out myReturn)

{

//

//

}

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Doh!!

Seems I have figured it out...

I needed to specify the def. within the method and then it works eg:

protected override void Bapi_Customer_Display (

string myCustNum,out BAPIRET1 myReturn)

{

myReturn = new BAPIRET1();

}