Forums - C# Corner

Forum guidelines
tarun janveja

tarun janveja

  • 1.4k
  • 175
  • 8.3k

json array with json object

Aug 15 2017 1:00 AM
i have below json code i am getting error .input string not in correct format .i require below format .
{"msisdn": ["1234","5432"]} .please rectify my code where i am doing wrong
string data;
List<string> s = new List<string>();
JArray msisdn = new JArray();
JObject o = new JObject();
o["msisdn"] = msisdn;
data = o["msisdn"];
Response.Write(data);   //error --input string is not in correct format

Answers (6)


Build smarter apps with Machine Learning, Bots, Cognitive Services - Start free.

Start Learning Now