Unexpected token in JSON at position 1405


#1

Unexpected token in JSON at position 1405

I am getting this error when I write this code.

this.sample.getSmartData(attachmentUrl,body).subscribe(data =>{
console.log(data);
let dataString=data.OutputParameters.GET_PR_ATTACHMENTS_F;
console.log(dataString);
let result=JSON.parse(dataString);
console.log(result);
});


#2

@Hanu1994
check your dataString variable contents it looks like it’s not a valid JSON data