{
"CompanyDtls": [{
"nComRefNo": 1,
"cName": "HOLIDAY DEMO",
"cSHName": "HDEM",
"cAddress1": "XXXX-XXXX",
"cAddress2": "XXX-SSSS",
"cAddress3": "XXXXX-XXXXX",
"nCreatedBy": 0,
"dCreatedDate": "\/Date(1274725800000+0530)\/",
"nModifiedBy": 0,
"dModifiedDate": "\/Date(1408645800000+0530)\/",
"bCancelled": "0 ",
"bActive": true,
"cLTNO": "LT:1522552522",
"cSTNo": "SR.NO:3255255",
"cPhoneNo": "XXXX-XXXXX",
"cTIN": "PAN:25522451 TAN:25522451"
}],
"ReportDtls": [{
"Srl": "",
"Date": "\/Date(1421605800000+0530)\/",
"BillFolio": "223/0",
"GRCNo": 432236,
"Guest": "ASSDSS",
"Room": "208",
"Charge": 1650807.840,
"Refund": 0.000,
"Disc": 0.000,
"Tax": 328751.700,
"Gross": 1979559.540,
"Advance": 1111.000,
"Tips": 0.000,
"AddCharge": 0.000,
"RoundOff": 0.460,
"CashAmt": 0.000,
"CreditAmt": 1978449.000,
"BillAmt": 1978449.000,
"User": "ADMIN",
"nFinalBillId": 3417
}, {
"Srl": "",
"Date": "\/Date(1422383400000+0530)\/",
"BillFolio": "225/1",
"GRCNo": 432287,
"Guest": "Agent",
"Room": "208",
"Charge": 8340.540,
"Refund": 0.000,
"Disc": 0.000,
"Tax": 1659.470,
"Gross": 10000.010,
"Advance": 0.000,
"Tips": 0.000,
"AddCharge": 0.000,
"RoundOff": -0.010,
"CashAmt": 10000.000,
"CreditAmt": 0.000,
"BillAmt": 10000.000,
"User": "ADMIN",
"nFinalBillId": 3419
}]
我是新來的android編程,我想知道,我如何解析一個json,它有兩個這樣的數組節點?我通過一些例子,但找不到我在找什麼。解析json與多個陣列節點
在此先感謝。
顯示什麼ü試圖 –
JSON有2個陣列'CompanyDtls'和'ReportDtls'。第一個有1個元素,第二個有2個,你可以像訪問數組元素一樣訪問每個元素。 –
http://stackoverflow.com/a/9606629 – Sree