title: ArrayAdapter remove does not work
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/7200331/unsupportedoperationexception-with-arrayadapter-remove">UnsupportedOperationException with ArrayAdapter.remove</a>  </p>
  </blockquote>
  
  
  
  <p>I have a listview which will be refreshed when the user clicks a delete button.
  For some reason I get this error</p>
  
  <blockquote>
    <p>02-19 17:16:47.231: E/AndroidRuntime(1118): FATAL EXCEPTION: main
    02-19 17:16:47.231: E/AndroidRuntime(1118): java.lang.UnsupportedOperationException
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at java.util.AbstractList.remove(AbstractList.java:645)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at java.util.AbstractList$SimpleListIterator.remove(AbstractList.java:77)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at java.util.AbstractCollection.remove(AbstractCollection.java:230)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.widget.ArrayAdapter.remove(ArrayAdapter.java:212)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at com.DCWebMakers.Vairon.ManageAppointment.onClick(ManageAppointment.java:102)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.view.View.performClick(View.java:2485)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.view.View$PerformClick.run(View.java:9080)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.os.Handler.handleCallback(Handler.java:587)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.os.Handler.dispatchMessage(Handler.java:92)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.os.Looper.loop(Looper.java:123)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at android.app.ActivityThread.main(ActivityThread.java:3683)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at java.lang.reflect.Method.invokeNative(Native Method)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at java.lang.reflect.Method.invoke(Method.java:507)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
    02-19 17:16:47.231: E/AndroidRuntime(1118):     at dalvik.system.NativeStart.main(Native Method)</p>
  </blockquote>
  
  <p>This is the code when removing the item.</p>
  
  <pre><code>detailAdapter.remove(eDelete.getText().toString());
  detailAdapter.notifyDataSetChanged();
  </code></pre>