Hi

I am using XMLtoJSON forge component where in I have to provide XML as input parameter. Now this parameter's datatype is text, when I am providing xml as an expression, it is throwing up errors. Need Solution to this.


Thanks in advance!

Hi Gaurav,

Whenever you embed an external data source i.e. a variable value within a string make sure to include the variable in between " + Variable + ". Refer the below mentioned example..

Syntax

"<PUB TYPE = " + DocTypeValue+ ">
<PARA TYPE = " + BodyValue +">
"

 

Hope this helps you!


Regards,

Benjith Sam

Gaurav Pandey wrote:

Hi

I am using XMLtoJSON forge component where in I have to provide XML as input parameter. Now this parameter's datatype is text, when I am providing xml as an expression, it is throwing up errors. Need Solution to this.


Thanks in advance!

you should use single quotes inside double quotes or you need to use a format like: "<?XML version=" + 1 + "." + 0+"?>.....


when you use this " you close your text string