Skip to Content
avatar image
Former Member

Personas 3.0 RFC calls returning null values


I am trying to incorporate RFC calls into some Personas scripts but they seem to be returning null values.  I tested in SE37 the same function modules, same inputs and the expected values are returned.  I decided to try one of the simple examples from the portal the and get the same result.  Here is the code:

var rfc = session.createRFC("BAPI_USER_GET_DETAIL");

rfc.setParameter("USERNAME", "*******");



var address = JSON.parse(rfc.getResult("ADDRESS"));

Here is the error:

Error during script execution:

TypeError: Cannot read property 'textContent' of null

at sap.personas.scripting.scriptingEngine.GuiRFC.getResult (http://svrsaperpdev.mcc.local:8100/sap/bc/personas3/core/script/sap/personas/fw/its/scripting/ScriptingEngine.js?20160323161651:30:1953)

at eval ([AppID:VA01]>[Flavor:VA01_RM_01_TEMP]>[Script:wnd[0]/scrptPersonas_0-GOTO_DETAIL]:50:30)

at Object.self.executeScriptInternal (http://svrsaperpdev.mcc.local:8100/sap/bc/personas3/core/script/sap/personas/fw/its/scripting/ScriptingEngine.js?20160323161651:45:9330)

at (http://svrsaperpdev.mcc.local:8100/sap/bc/personas3/core/script/sap/personas/fw/its/scripting/ScriptingEngine.js?20160323161651:45:11630)

at eval (http://svrsaperpdev.mcc.local:8100/sap/bc/personas3/core/script/sap/personas/fw/its/scripting/Runtime.js:1:659)

Since I get the same error on all FMs I have tried could this be something related to the RFC connection?  How to find out what RFC connection is used in this case?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Apr 26, 2016 at 04:32 PM

    Hello Rob,

    Have you maintained the FM in the whitelist?

    /n/personas/admin -> menu "Goto" -> "Whitelists" -> "FM Whitelist".

    Please also visit the Wiki "How to call Remote Enabled ABAP Function Modules in Personas 3.0"

    Kind regards,


    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Tamas Hoznek

      Thanks so much Tamas.  I was capturing the customer number from the actual field in the transaction, but it seems it does not include the leading zeros when doing so.  I have added some code to insert the leading zeros and it is working as expected.