title: On Click Listener on subview of list item from custom adapter
body: <p>I am using getview method of baseadapter class for filling the data into listview. And it is working great. I have a relative layout in every listitem through which i am playing a audiofile. I am using onclicklistener in getview method as shown below.</p>
  
  <pre><code>@Override
  public View getView(int position, View convertView, ViewGroup parent) {
      // TODO Auto-generated method stub
      View vi = convertView;
  
      if (convertView == null)
          vi = inflater.inflate(R.layout.chatbubbles_listrow, null);
      context = parent.getContext();
  
      TextView date = (TextView) vi.findViewById(R.id.date);
      RelativeLayout playaudio = (RelativeLayout) vi
              .findViewById(R.id.audio_image);
      HashMap&lt;String, String&gt; events = new HashMap&lt;String, String&gt;();
      events = data.get(position);
      final String restype = events.get(Conversation.TAG_USERTYPE);
      audiopath = events.get(Conversation.TAG_AUDIOPATH);
      playaudio.setOnClickListener(new View.OnClickListener() {
  
          @Override
          public void onClick(View v) {
              // TODO Auto-generated method stub
              stopPlayBack();
              Toast.makeText(context, audiopath, Toast.LENGTH_SHORT).show();
              Log.e("On Click path", audiopath);
              new LoadChats().execute();
          }
      });
  
       date.setText(restype + audiopath);
      return vi;
  }
  </code></pre>
  
  <p>My listview is showing all information correct as i want but when i click the relative layout then a audio play which is correct to be played but when i click on another relative layout the same audio play again which is wrong. every listitem have is own audio path that must be played but here only one audio play which is played earlier. I know the problem is with onClicklistner of playaudio but I am not getting the problem. It blows up my mind. Please help.</p>
  
  <p><strong>Thanks in advance</strong></p>