title: long click method to delete item from listview
body: <blockquote>
    <p>could any one help me that how to perform long click option in list
    view item's so i able to delete my notes from sq lite database ...i
    have 2 column in my note app they are id ,title and notetext</p>
  </blockquote>
  
  <p>my code to create table is ..</p>
  
  <pre><code>mydb1 = Main1Activity.this.openOrCreateDatabase("185", MODE_PRIVATE, null);
  
  mydb1.execSQL("CREATE TABLE IF NOT EXISTS notes (id INTEGER PRIMARY KEY AUTOINCREMENT,title varchar,notetext varchar);");
  </code></pre>
  
  <p>long click code </p>
  
  <pre><code>lv.setOnItemLongClickListener(new OnItemLongClickListener(){
      public boolean onItemLongClick(AdapterView&lt;?&gt; arg0, View arg1, int arg2,long arg3) {
          data.remove(arg2);
          // adapter.notifyDataSetChanged();
          //adapter.notifyDataSetInvalidated();
          return true;
      }
  });
  </code></pre>