How to extract json data?
<p><em>I am getting this trouble?</em></p>

<pre><code>[
{
    "username": "apap",
    "status": "",
    "log": "",
    "email": "apap@gmail.com",
    "lat": "",
    "dob": "5-11-1986"
},
{
    "username": "apapp",
    "status": "",
    "log": "",
    "email": "apapp@gmail.com",
    "lat": "",
    "dob": "5-11-1986"
}
],
"returncode": "0"
}
</code></pre>

<p><strong>Error parsing data org.json.JSONException: Value {"incircle": at response of type org.json.JSONObject cannot be converted to JSONArray</strong></p>

<p><em>For extracting incircle array value,I am writing following code:</em></p>

<pre><code>public class MainActivity extends Activity {
TextView username;
TextView email;
TextView dob;
TextView lat;
TextView log;
ListView listView;
ArrayList&lt;HashMap&lt;String,String&gt;&gt; jsonlist;
JsonAdapter objAdapter;
Context ctx;

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);
    listView = (ListView) findViewById(R.id.listView);
    jsonlist = new ArrayList&lt;HashMap&lt;String,String&gt;&gt;();
    JSONObject json = JSONfunctions
            .getJSONfromURL("http://www.railsboxtech.com/flirtalert/alluser.php");

    try {

        JSONArray flirt = json.getJSONArray("response");
        Toast.makeText(MainActivity.this, "namr", Toast.LENGTH_LONG).show();
        for (int i = 0; i &lt; flirt.length(); i++) {

            JSONObject ei = flirt.getJSONObject(i);
            JSONArray eie = ei.getJSONArray("incircle");
            for (int j = 0; j &lt; eie.length(); j++) {
                JSONObject e = eie.getJSONObject(j);
                HashMap&lt;String, String&gt; map = new HashMap&lt;String, String&gt;();
                map.put("User",e.getString("username"));
                map.put("Email",e.getString("email"));
                map.put("dob",e.getString("dob"));
                map.put("lat",e.getString("lat"));
                map.put("log",e.getString("log"));
                jsonlist.add(map);

            }

        }
    } catch (JSONException e) {
        Log.e("log_tag", "Error parsing data " + e.toString());
    }
    ListAdapter adapter = new SimpleAdapter(this, jsonlist, R.layout.user_list,
            new String[] { "User", "Email","dob","lat","log"}, new int[] {
                    R.id.username, R.id.email, R.id.dob, R.id.lat, R.id.log});
    listView.setAdapter(adapter);
    listView.setTextFilterEnabled(true);

}

@Override
public boolean onCreateOptionsMenu(Menu menu) {
    getMenuInflater().inflate(R.menu.main, menu);
    return true;
}
</code></pre>

<p>}</p>
