Android edittext in listview loses focus on calling notifydatachanged

Set

android:windowSoftInputMode="adjustPan"

for your activity in the AndroidManifest.xml


It is indeed happening because all the views are redrawn, so the edit text representing whatever row used to be focused is now a completely different object. Set a variable in your adapter: int currentlyFocusedRow;

in getView for your adapter: Add an onFocusChanged listener to each edit text and when that edit text gains focus, set currentlyFocusedRow = whatever row the focused edit text happens to be in. Also set any edit text that is in the currentlyFocusedRow to be focused.