You need to sign in to do that
Don't have an account?
rupesh ranjan
Handling error escaped using backslash to be included in string
System.JSONException: Illegal unquoted character ((CTRL-CHAR, code 13)): has to be escaped using backslash to be included in string value at [line:1, column:215]
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\WraPPER Class///////////////////////////////////////////
public class demomailsentwrap {
public String TotalViewCount{get;set;}
public String echo{get;set;}
public String TotalRecords{get;set;}
public String TotalDisplayRecords{get;set;}
public List<GroupData> GroupData{get;set;}
public class GroupData
{
public String ID;
public String Title;
public String CompanyName;
public String SessionTitle;
public String ViewedDate;
public String DurationStr;
public String location;
public String IsVirtualContact;
public String Groupcontact;
public String name;
public String email;
}
}
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\APEX\\\\\\\\\\\\\\\\\\\\\\\
public class demomailsent{
public List<demomailsentwrap> ConsoleWrapperList{get;set;}
public List<demomailsentwrap> getperformcallout(){
ConsoleWrapperList = new List<demomailsentwrap>();
HttpRequest req = new HttpRequest();
HttpResponse res = new HttpResponse();
Http http = new Http();
req.setEndpoint('http://webapi.demomail.net/test/DemomailSent.js');
req.setMethod('GET');
//req.setHeader('Authorization', 'OAuth '+UserInfo.getSessionId());
res = http.send(req);
//System.assert(false,res.getBody()+'******');
if(res.getstatusCode() == 200 && res.getbody() != null)
{
ConsoleWrapperList=(List<demomailsentwrap>)System.JSON.deserialize(res.getbody(),List<demomailsentwrap>.class);
//System.debug('Response Checking Engine: '+ res.getBody());
}
return consolewrapperlist;
}
}
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\WraPPER Class///////////////////////////////////////////
public class demomailsentwrap {
public String TotalViewCount{get;set;}
public String echo{get;set;}
public String TotalRecords{get;set;}
public String TotalDisplayRecords{get;set;}
public List<GroupData> GroupData{get;set;}
public class GroupData
{
public String ID;
public String Title;
public String CompanyName;
public String SessionTitle;
public String ViewedDate;
public String DurationStr;
public String location;
public String IsVirtualContact;
public String Groupcontact;
public String name;
public String email;
}
}
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\APEX\\\\\\\\\\\\\\\\\\\\\\\
public class demomailsent{
public List<demomailsentwrap> ConsoleWrapperList{get;set;}
public List<demomailsentwrap> getperformcallout(){
ConsoleWrapperList = new List<demomailsentwrap>();
HttpRequest req = new HttpRequest();
HttpResponse res = new HttpResponse();
Http http = new Http();
req.setEndpoint('http://webapi.demomail.net/test/DemomailSent.js');
req.setMethod('GET');
//req.setHeader('Authorization', 'OAuth '+UserInfo.getSessionId());
res = http.send(req);
//System.assert(false,res.getBody()+'******');
if(res.getstatusCode() == 200 && res.getbody() != null)
{
ConsoleWrapperList=(List<demomailsentwrap>)System.JSON.deserialize(res.getbody(),List<demomailsentwrap>.class);
//System.debug('Response Checking Engine: '+ res.getBody());
}
return consolewrapperlist;
}
}
you have to get rid of some `illegal characters`, which can't be parsed.
This should help:
Marek
All Answers
you have to get rid of some `illegal characters`, which can't be parsed.
This should help:
Marek
thank you so much :)
Woking fine.