Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- "resultCode":"OK",
- "configs":[
- {
- "configID":"1",
- "configName":"Data Limit",
- "configValue":"5000000"
- },
- {
- "configID":"2",
- "configName":"Connectivity Settings Frequency",
- "configValue":"55"
- },
- {
- "configID":"3",
- "configName":"User Tracking Frequency",
- "configValue":"56"
- },
- {
- "configID":"4",
- "configName":"Data Monitoring Frequency",
- "configValue":"57"
- },
- {
- "configID":"5",
- "configName":"User Device Frequency",
- "configValue":"58"
- },
- {
- "configID":"6",
- "configName":"Telephony Settings Frequency",
- "configValue":"59"
- },
- {
- "configID":"7",
- "configName":"Restrictions Settings Frequency",
- "configValue":"60"
- },
- {
- "configID":"8",
- "configName":"DateTime Settings Frequency",
- "configValue":"61"
- },
- {
- "configID":"9",
- "configName":"Advanced Settings Frequency",
- "configValue":"62"
- }
- ],
- "companyInfo":{
- "companyID":"1",
- "companyName":"Test Company",
- "webServiceGuid":"11E0662D-6672-406C-977A-4BE9124B3E35",
- "url":"http://devreach2.yourofficeanywhere.co.uk/",
- "portNumber":"51000"
- },
- "user":{
- "userID":"8",
- "samsungApiKey":"ABC",
- "surname":"Womersley"
- }
- }
- JSONObject mainObject = new JSONObject(result);
- Log.e(TAG, "mainObject = " + mainObject);
- resultCode = mainObject.get("resultCode").toString();
- Log.e(TAG, "resultCode = " + resultCode);
- cv.put("resultcode", resultCode);
- JSONObject user = mainObject.getJSONObject("user");
- Log.e(TAG, "user object = " + user);
- String userID = user.getString("userID");
- Log.e(TAG, "userID = " + userID);
- cv.put("userid", userID);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement