06-18-2019 1:36 PM
erros-xstring.pngGood Morning.
I am creating an RFC and managed an Enterprise Service (SOAP)
The RFC should receive a parameter of type Xstring. This parameter will convert to binary (SCMS_XSTRING_TO_BINARY).
However when testing, the error of the attached image is occurring.
How can I pass an Xtring value as a parameter?
06-18-2019 4:38 PM
As suggested by Sandra Rossi I am passing as string and inside the RFC again converting to xstring, the error has been solved. Thank you all.
06-18-2019 1:45 PM
Everything we can tell you is in the error message.
Somewhere in your program you are probably trying to decode Base64 string and it fails.
06-18-2019 2:44 PM
The first bytes "89504E47..." in your log, correspond to the bytes of a PNG file, but they are not encoded in base64. If you define a parameter of type XString, and you create a Web service around, then SAP framework expects a Base64 string and decodes it into an Xstring. Solution: call your web service with your PNG encoded into Base64. Another solution, maybe, is to map to a different type in your service definition (tab "Types").
06-18-2019 4:05 PM
I would check the possibility of encoding and decoding using ABAP class CL_HTTP_UTILITY.
06-18-2019 4:10 PM
I would check the possibility of encoding and decoding to base64 using CL_HTTP_UTILITY.
06-18-2019 4:38 PM
As suggested by Sandra Rossi I am passing as string and inside the RFC again converting to xstring, the error has been solved. Thank you all.