Quantcast
Viewing all articles
Browse latest Browse all 8533

Re: Issues while Calling a WebRFC from Personas

Hi Steve/Sushant/Tamas,

 

Thanks for responding. Let me try and elaborate the scenario and hopefully this will be more helpful than my earlier posts. Please bear with me for the length of the content.

 

The Scenario

--------------------------------------------------------------------------------------------------

I am trying to update addresses for employee. here is a look at permanent address block.

Image may be NSFW.
Clik here to view.
Scenario.PNG

I am using a Z FM with the signature required for WebRFC.

Image may be NSFW.
Clik here to view.
FM_Signature.PNG

In this I am calling a BAPI BAPI_ADDRESSEMP_CREATE. I have tested this BAPI several times and it works well. I have tested it even further after the FM development. I have manually added values in QUERY_STRING table and it has always worked.

Image may be NSFW.
Clik here to view.
BAPI_Call.PNG

I am generating url in these two steps.

Image may be NSFW.
Clik here to view.
Url generation 1.PNG

The code in step11 is

args.srv_sys_rfc = "http://devmssbx01.fmgdev.local:8001/sap/bc/webrfc?_FUNCTION=Z_HR_PERS_0006_CREATE&_SUBTYPE=1";

The code is step 12 is

args.url = args.srv_sys_rfc+"&_PNO="+args.pno+"&_FROM="+args.from+"&_PERMADDRESSL1="+args.permaddressl1+"&_PERMADDRESSL2="+args.permaddressl2+"&_PERMCITY="+args.permcity+"&_PERMPOSTCODE="+args.permpostcode+"&_PERMREGION="+args.permregion+"&_PERMMOBILE="+args.permmobile;

 

The Problem

-------------------------------------------------------------------------

After calling the script, this is the url that I see in the text box.

 

http://devmssbx01.fmgdev.local:8001/sap/bc/webrfc?_FUNCTION=Z_HR_PERS_0006_CREATE&_SUBTYPE=1&_PNO=526771&_FROM=12.01.2014&_PERMADDRESSL1=Address Line 1&_PERMADDRESSL2=Address Line 2&_PERMCITY=City&_PERMPOSTCODE=null&_PERMREGION=null&_PERMMOBILE=null

 

However, I get a runtime error.

Image may be NSFW.
Clik here to view.
Error Message.PNG

If I call this from Personas, it always fails. If I paste it in browser, I always get either error message regarding the validations and upon fixing them, I get success message. See n example below for same url.

 

Image may be NSFW.
Clik here to view.
IE_WebRFC_Call_Validation_Error1.PNG

 

Image may be NSFW.
Clik here to view.
IE_WebRFC_Call_Validation_Error2.PNG

 

Image may be NSFW.
Clik here to view.
IE_WebRFC_Call_Success.PNG

After this experience I ommitted the fields with NULL value and generated url only till permaddressl1 and permadderssl2 still it fails from Personas and works well in IE url bar.

 

Hopefully I have provided sufficient details for analysis. If you need anything let me know.

 

Regards

Abhi


Viewing all articles
Browse latest Browse all 8533

Trending Articles



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