I followed this tutorial about parsing JSON. All is working as it should have have edited it to more my needs. I am getting information about 'servers' and one of the fields is 'status' (either UP or DOWN). 

EDIT: forgot to post tutorial link <http://www.androidhive.info/2012/01/android-json-parsing-tutorial/>

It currently looks like this: <http://puu.sh/8Ky0B.jpg>
The above is what happens then the app is loaded. the on click is when a single item is clicked it starts a new activity and shows that information individually.

You can see the second server status is 'DOWN'. Based on this I want to change the text colour to RED for down and keep it green for up.

How can I do this when it goes through and adds each listview?

Here is the code which (currently) is basically the same as the tutorial:

```
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);

    serverList = new ArrayList<HashMap<String, String>>();

    ListView lv = getListView();

    // Listview on item click listener
    lv.setOnItemClickListener(new OnItemClickListener() {

        @Override
        public void onItemClick(AdapterView<?> parent, View view,
                int position, long id) {
            // getting values from selected ListItem
            String name = ((TextView) view.findViewById(R.id.name))
                    .getText().toString();
            String ip = ((TextView) view.findViewById(R.id.ipAddress))
                    .getText().toString();
            String status = ((TextView) view.findViewById(R.id.serverStatus))
                    .getText().toString();

            // Starting single server activity
            Intent in = new Intent(getApplicationContext(),
                    SingleContactActivity.class);
            in.putExtra(TAG_NAME, name);
            in.putExtra(TAG_IP, ip);
            in.putExtra(TAG_STATUS, status);
            startActivity(in);
        }
    });

    // Calling async task to get json
    new GetContacts().execute();
}

/**
 * Async task class to get json by making HTTP call
 * */
private class GetContacts extends AsyncTask<Void, Void, Void> {

    @Override
    protected void onPreExecute() {
        super.onPreExecute();
        // Showing progress dialog
        pDialog = new ProgressDialog(MainActivity.this);
        pDialog.setMessage("Please wait...");
        pDialog.setCancelable(false);
        pDialog.show();
    }

    @Override
    protected Void doInBackground(Void... arg0) {
        // Creating service handler class instance
        ServiceHandler sh = new ServiceHandler();

        // Making a request to url and getting response
        String jsonStr = sh.makeServiceCall(url, ServiceHandler.GET);

        Log.d("Response: ", "> " + jsonStr);

        if (jsonStr != null) {
            try {
                JSONArray jArray = new JSONArray(jsonStr);

                // looping through All Servers
                for (int i = 0; i < jArray.length(); i++) {
                    JSONObject c = jArray.getJSONObject(i);

                    String id = c.getString(TAG_ID);
                    String name = c.getString(TAG_NAME);
                    String ip = c.getString(TAG_IP);
                    String status = c.getString(TAG_STATUS);

                    // tmp hashmap for single server
                    HashMap<String, String> contact = new HashMap<String, String>();

                    contact.put(TAG_ID, id);
                    contact.put(TAG_NAME, name);
                    contact.put(TAG_IP, ip);
                    contact.put(TAG_STATUS, status);

                    // adding server to server list
                    serverList.add(contact);
                }
            } catch (JSONException e) {
                e.printStackTrace();
            }
        } else {
            Log.e("ServiceHandler", "Couldn't get any data from the url");
        }
        return null;
    }

    @Override
    protected void onPostExecute(Void result) {
        super.onPostExecute(result);
        // Dismiss the progress dialog
        if (pDialog.isShowing())
            pDialog.dismiss();
        /**
         * Updating parsed JSON data into ListView
         * */

        ListAdapter adapter = new SimpleAdapter(
                MainActivity.this, serverList,
                R.layout.list_item, new String[] { TAG_NAME, TAG_IP,
                        TAG_STATUS }, new int[] { R.id.name,
                        R.id.ipAddress, R.id.serverStatus });

        setListAdapter(adapter);
    }

}

```