Quantcast
Channel: SCN: Message List - ABAP Connectivity
Viewing all articles
Browse latest Browse all 3125

RFC doesnt work when import parameter is passed from Jco

$
0
0

Hi,

 

I am passing import parameter from JCO to RFC , however it doesn't work

Following are the code:

 

 

        JCoDestination destination = JCoDestinationManager.getDestination(DESTINATION_NAME2);

        JCoFunction function = destination.getRepository().getFunction("ZTEST_BAPI_SALES");

        ;

        if (function == null)

            throw new RuntimeException("ZTEST_SALES not found in SAP.");

       

 

       JCoParameterList ipl=function.getImportParameterList();

       ipl.setValue("WERKS","5200");

 

        try {

 

 

           

            function.execute(destination);

 

           

        } catch (AbapException e) {

            System.out.println("error in fetching data: "+e.toString());

           

            return;

        }

 

        System.out.println(" Response: " + function.getExportParameterList().getString("RETURN"));

 

Pls help.

Regards,

Asia Khan


Viewing all articles
Browse latest Browse all 3125

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>