kiran lad

kiran lad

  • NA
  • 100
  • 574

How to call web API from Xamarin visual studio 2015

Feb 6 2018 3:54 AM
Dear All,
 
I have created web api its returning me output as
 
{"lst_Assign_To_1":[{"Selected":false,"Text":"test1","Value":"63"},{"Selected":false,"Text":"test2","Value":"7"}]}
 
and trying to consume in json in my xamarin visual studio 2015 application. while consuming that i am getting error Unable to Evaluae expression.
 
Below are my classes
 
public class ClassA
{
public ClassB objClassB { get; set; }
public List<string> lst_Assign_To_New { get; set; }
[JsonProperty(PropertyName = "lst_Assign_To_1")]
public List<ClassB> lst_Assign_To_1 { get; set; }
}
public class ClassB
{
[JsonProperty(PropertyName = "Selected")]
public bool Selected { get; set; }
[JsonProperty(PropertyName = "Text")]
public string Text { get; set; }
[JsonProperty(PropertyName = "Value")]
public string Value { get; set; }
}