I’m wondering if it is possible to clear data from a customized dialog. I have a customized dialog having 5 textview and edittexts. I have two buttons named “Send ” and “Clear” first is supposed to send the data to database and second is meant to clear the data, in case if user wants to re-enter the whole text there in the 5 edittext fields.
Any idea how to do this?
SIMPLE:
You want to set the text of the editText to an empty string or “”.
IN DEPTH:
You need to import:
Make sure you have this below your onCreate:
Onclick you want to:
OVERKILL:
Here is how I would do it: