Creating a list within a list

With support, I have created a list of arrays that populates JSON data. When a user clicks on an item in the list of arrays, it takes them to an activity page that provides them more information about that particular item.

In particular, below are my 3 questions:

  1. In the single item page, I added an "add more" button, and I would want that when the button is click, that particular item gets recorded until 3 different item in the list of arrays have been selected.

  2. I would want to update the user of how many item have been selected thus far in a textview in the single item page.

  3. I have added a confirm button, but I would want to set a condition, where it would only go to the next activity once 3 item have been selected.

  4. Transmit the user recorded information to Where every time, a user click on add more, it updates parse on the activity that have been selected by the user, where I could have three column for activity 1, activity 2, and activity 3 within my class.

Below is my list of arrays code:

public class EventsActivity extends Activity{

    private static final String URL_WEB_SERVICE = "";
    private GridView gv;
    private ArrayList<Events_List> container;
    private ArrayList<Events_List> items;
    public Uri list_item_bac;
    public String list_item_name;
    public String list_item_description;
    public String single_list_item_description;
    public String list_item_price;

    protected void onCreate(Bundle savedInstanceState) {
        gv = (GridView) findViewById(;
        container = new ArrayList<Events_List>();
        //download JSON

        GridView s = (GridView) findViewById(;
        s.setOnItemClickListener(new OnItemClickListener(){

            public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
                Intent intent = new Intent(EventsActivity.this,EventSingleItemActivity.class);
                intent.putExtra("list_item_name", container.get(position).getList_item_title());
                intent.putExtra("single_list_item_description", container.get(position).getSingle_list_item_description());
                startActivity(intent); //start Activity
    public void listDownload(){
        RequestQueue volley = Volley.newRequestQueue(this);
        JsonObjectRequest json = new JsonObjectRequest(Method.GET, URL_WEB_SERVICE, null, ResponseListener(), ErrorListener());

    private Response.Listener<JSONObject> ResponseListener() {
        return new Response.Listener<JSONObject>() {
            public void onResponse(JSONObject response) {
                try {
                    //your JSON Array
                    JSONArray array = response.getJSONArray("list_item");
                    for(int i = 0; i < array.length(); i++){
                } catch (JSONException e) {
                gv.setAdapter(new AdapterEvents(getApplicationContext(),container));

    private Response.ErrorListener ErrorListener() {
        return new Response.ErrorListener() {
            public void onErrorResponse(VolleyError error) { }

    //object JSON
    private final Events_List convertirAnuncio(JSONObject obj) throws JSONException {
        long id = obj.getLong("id"); //id 
        String list_item_name = obj.getString("list_item_name"); 
        String list_item_description = obj.getString("list_item_description");
        String single_list_item_description = obj.getString("single_list_item_description");
        Uri uri = Uri.parse(obj.getString("list_item_bac"));
        return new Events_List(id,single_list_item_description,list_item_name,list_item_description,list_item_price, uri);

Below is my single item click page

public class EventSingleItemActivity extends Activity {
    // Declare Variables
    String list_item_name;
    String list_item_description;
    String list_item_price;
    String single_list_item_description;

    public void onCreate(Bundle savedInstanceState) {


        Intent i = getIntent();
        list_item_name = i.getStringExtra("list_item_name");
        single_list_item_description = i.getStringExtra("single_list_item_description");

        TextView txtname = (TextView) findViewById(;
        TextView txtsdescription = (TextView) findViewById(;

        // Set results to the TextViews

        Button mConfirm2 = (Button)findViewById(;
        mConfirm2.setOnClickListener(new View.OnClickListener() {

            public void onClick(View v) {
                EventSingleItemActivity.this.startActivity(new Intent(EventSingleItemActivity.this, MatchingActivity.class));

        Button mcancel = (Button)findViewById(;
        mcancel.setOnClickListener(new View.OnClickListener() {

            public void onClick(View v) {
                EventSingleItemActivity.this.startActivity(new Intent(EventSingleItemActivity.this, EventsActivity.class));


I have looked into the following tutorial:
but this is not exactly what I want to achieve.

Source: Android Layout Questions