Cannot deserialize the current JSON object into type 'System.Collections.Generic.List

前端 未结 3 1166
深忆病人
深忆病人 2021-01-25 23:44

I am trying to read my JSON result.

Here is my JsonResult

public class JsonResult
    {
    public string ResponseStatus;
    public string Status;
    p         


        
3条回答
  •  甜味超标
    2021-01-25 23:58

    If you want to send list of data List then in JSON it should be in a form of array

    Change the following JSON content

    "Data": {"Status":"Pending",
    "Date":"2017-02-23T17:22:26.2001954+05:30",
    "Number":"9915933511",
    "Amount":10.0,"Balance":137.714,
    "TranId":"1126887","OPTId":"","RefId":""}
    

    To

    "Data": [{"Status":"Pending",
    "Date":"2017-02-23T17:22:26.2001954+05:30",
    "Number":"9915933511",
    "Amount":10.0,"Balance":137.714,
    "TranId":"1126887","OPTId":"","RefId":""}]
    

提交回复
热议问题