In Android Studio, I want to make a program where a TextView
changes to an EditView
when clicked. After the user is finished typing, I want the EditText
to then change back to a TextView
which shows the value that was entered.
How do I do this? This is what I have so far:
loc > TextView,
edit_loc > EditText
loc.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
loc.setVisibility(View.GONE);
edit_loc.setVisibility(View.VISIBLE);
}
});