Ramu ramu's Profile

15
Points

Questions
6

Answers
1

  • Asked on May 26, 2017 in android.
    JsonObjectRequest objectRequest=new JsonObjectRequest(Request.Method.POST, url, obj,
     new Response.Listener<JSONObject>() {
     @Override
     public void onResponse(JSONObject response) {
     try {
     JsonArray array1=response.getJsonArray("array1");
     for(int i=0;i<array1.length();i++){
     JsonObject o=array1.getJSONObject(i);
     }
     JsonArray array2=response.getJsonArray("array2");
     for(int j=0;j<array2.length();j++){
     JsonObject o=array2.getJSONObject(i);
     }
     } catch (JSONException e) {
     e.printStackTrace();
     }
     }
     },
     new Response.ErrorListener() {
     @Override
     public void onErrorResponse(VolleyError error) {
     Log.e("Error",""+error);
     }
     });
     mRequestQueue.add(objectRequest);
     }
    }
    
    • 63 views
    • 1 answers
    • 0 votes