UpdateReceiveParams Method
Retrieves the receive parameters for the function that was called.
Syntax
public void updateReceiveParams();
Remarks
When the SAP system calls your installed function, the FunctionCall event will fire with the name of the function
being called. To process this function call, the first thing you must do is retrieve the ReceiveParams. The
ReceiveParams collection starts off empty. You must add the names of the parameters you wish to receive, and then
call UpdateReceiveParams. If the caller of the function provided values for the parameters you indicated, each
parameter contained in the ReceiveParams collection will now contain a value.
For instance:
SapServer1.ReceiveParams.Add(new nsoftware.InERP.SapParam("FIRSTNAME", "",ptCharacters)); SapServer1.ReceiveParams.Add(new nsoftware.InERP.SapParam("LASTNAME", "", ptCharacters)); SapServer1.UpdateReceiveParams();If the remote function caller provided the name "John Smith", then SapServer1.ReceiveParams[0].Value will contain "John" and SapServer1.ReceiveParams[1].Value will contain "Smith" after calling the UpdateReceiveParams method. If you ask for parameters that were not supplied, the Values for those parameters will remain empty. If the remote caller supplied additional parameters that you did not request the values of, they will be ignored and no information on those parameters will be contained in the ReceiveParams collection. There is unfortunately no way to receive all parameters supplied by the remote caller. This is a limitation of the underlying SAP RFC interface.
This method can only be used inside the FunctionCall event.
Please note that this method is invalid when using JCo, the parameters will automatically be updated as they are added.