Listview with Sections:How to identify which item of perticular section is clicked
<p>I am using setOnItemClickListener for the list with sections. I have two sections in this list I want that if any item/row of 1st section is clicked it sholud start new activity and If any item of 2nd section is click it should do nothing. How can i identify that the item belong to which section???? Please help
code snippet</p>

<pre><code> SectionedAdapter adapter = new SectionedAdapter() {
             protected View getHeaderView(String caption, int index,View convertView, ViewGroup parent) {
                 TextView result = (TextView) convertView;


                 if (convertView == null) {
                     result = (TextView) getLayoutInflater().inflate(R.layout.header, null);
                 }
                 if(caption != null){ 
                        result.setText(caption); 
                        }else{ 
                            result.setVisibility(View.GONE); 
                        } 


                 return (result);
             }
         };

                    ListView lister;
                    @Override
                    public void onCreate(Bundle icicle) 
                    {
                      super.onCreate(icicle);
                      setContentView(R.layout.main);
                          lister=(ListView)findViewById(R.id.lister);
                      first();
                      second();
                     }
                    first()
                    {
                    arr=...// some array of elements to be in first list

                    firstadapter fa=new firstadapter(this,R.layout.list,arr);
                    adapter.addSection("Old",fa );
                    lister.setAdapter(adapter);

                   }
                  second()
                  {
                   arr=...// some array of elements to be in second list

                  secondadapter sa=new secondadapter(this,R.layout.list,arr);
                  adapter.addSection("Old",sa );
                  lister.setAdapter(adapter);

                  }
                 class firstAdapter extends BaseAdapter
                 {
                ...
                 }
                 class secondAdapter extends BaseAdapter
                 {
                ...
                 }

              abstract class SectionAdapter extends BaseAdapter
              {
         ...
               }
</code></pre>
