title: Android JSON Parsing JSONArray
body: <p>Why I am getting that NewsApp has no data? Why JSONArray not displaying data?</p>
  
  <p>This is the code-</p>
  
  <pre><code>    @Override
      protected void onPostExecute(Object o) {
          super.onPostExecute(o);
  
          try {
  
              Toast.makeText(NewsActivity.this, "Response: " + response.toString(), Toast.LENGTH_LONG).show();
  
              jsonObject = new JSONObject(response.toString());
  
              jsonArray = jsonObject.getJSONArray("NewsApp");
  
              Log.i("News",jsonArray.toString());
  
  
              for(int i=0;i&lt;jsonArray.length();i++){
  
                  JSONObject jObj = jsonArray.getJSONObject(i);
  
                  NewsInfo newsInfo = new NewsInfo();
  
                  //newsInfo.sourceName = jObj.getString("name");
                  newsInfo.author = jObj.getString("author");
                  newsInfo.title = jObj.getString("title");
                  newsInfo.description = jObj.getString("description");
                  newsInfo.url = jObj.getString("url");
                  newsInfo.urlImage = jObj.getString("urlToImage");
                  newsInfo.publishedAt = jObj.getString("publishedAt");
  
                  newsInfoArrayList.add(newsInfo);
  
              }
  </code></pre>