Android Volley: Send JSONObject as parameter and to receive JSONArray as response -
i'm learning volley library in android. i'm using jsonobjectrequest passing jsonobject request parameters, , i'm getting response jsonarray in error listener code jsonobjectrequest check line no.84 in image error in logcat.
can me regarding this, how jsonarray response passing jsonobject request parameter.
use jsonarrayrequest
capture array
in response
jsonarrayrequest jsonarrayrequest = new jsonarrayrequest( request.method.post, "http://lanes-dev.cloudapp.net/api/diarytweetlineapi/loaddiarytweetlinesbyuser", obj, new response.listener<jsonarray>() { @override public void onresponse(jsonarray response) { } }, new response.errorlistener(){ @override public void onerrorresponse(volleyerror error){ // when error occurred } } );
Comments
Post a Comment