JSON parsing trouble in android

view story

http://stackoverflow.com – I am getting a JSON array from server, something like:- [{"0":"13177","id":"13177",other key value pairs},{another object with key value},{ other JSON objects}] Now I am taking this as a string variable text(by input stream), and doing something like:- jsonpropertyarray=new JSONArray(text.trim());//jsonproperty is JSONArray variable I have a method in this class to return JSONArray: public static JSONArray searchresults() throws JSONException{ return jsonpropertyarray; } Now, in another class, I am invoking this method and getting JSON: jsonarray1=HttpConnectPropertySearch. (HowTos)