Skip to Content
Former Member
Dec 22, 2009 at 05:58 AM

Using RFC Look Up in Java Mapping


Hi All,

I need to do an RFC Look Up in a Java Mapping program. The response structure of the Function Module to be called consists of only one node called RESULT. In order to read the value exported by the function module in this export parameter RESULT, I am using the following code:

DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();

DocumentBuilder builder = null;



Document docResponse = null;

InputStream in1 = result.getContent();

docResponse = builder.parse(in1);

String output = docResponse.getDocumentElement().getFirstChild().getNodeValue();

The function module works correctly and returns the expected result when tested in SE37. However, on running the above code, the statement docResponse.getDocumentElement().getFirstChild().getNodeValue(); always returns the value NULL and not the expected value that is actually returned by the RFC.

Kindly let me know where could I be going wrong.

Thanks in advance.