Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Passing parameter to web-service as xsdany

Former Member
0 Kudos

Hello,

I need to call an external web service from sap.

I have successfully generated a proxy class from the wsdl, but the wsdl contains parameters of type anyType, that in the abap proxy are translated to type xsdany.

The problem is, i cannot transfer data to those parameters.

I used the function module scms_string_to_xstring to convert the data to the rawstring format, but altough i tried several encodings, i recieve the exception 'BOM / charset detection failed' when i call the web service.

How should i transfer the text to the xsdany format?

Thanks in advance,

Gershon

P.S. Not sure if this is the correct place for this question, but couldn't find any better.

2 REPLIES 2

Former Member
0 Kudos

In the end, the provider created version of the web service without using xsdany

Hi Gershon,

I came to the same issue these days and changing an external wsdl seems not to be the best solution to me.

Therefore I looked for an alternative.

My report using the client proxy failed with the error 'BOM / charset detection failed' while trying to pass string value to the variable.

I solved this issue by converting the string to an xstring either by function module SCMS_STRING_TO_XSTRING or xslt function call transformation ID

After that the proxy call was sucessful. Test if the webservice could deal with the result created by the proxy runtime have not been done yet.

Hope this helps.

Kind regards,

Jochen