I am making a app which sends the sms at the scheduled time. The schedule button perform the scheduling function. I have three text areas to get the user input. I want to reset these text area with the hints after I have pressed the schedule button. so, i have defined a function as:
public void resetInputFields() {
/**
* Resetting the text box to their initial values
*
* */
bdayMsg.setHint("Type your Message here..");
bdayMsg.setHintTextColor(R.color.text_grey);
phoneNum.setHint("Recipients..");
phoneNum.setHintTextColor(R.color.text_grey);
setBirthdayButton.setHint("Date");
setBirthdayButton.setHintTextColor(R.color.text_grey);
}
but setHint creates no effect while it works perfectly if i do the following:
ublic void resetInputFields() {
/**
* Resetting the text box to their initial values
*
* */
bdayMsg.setText("Type your Message here..");
bdayMsg.setTextColor(R.color.text_grey);
phoneNum.setText("Recipients..");
phoneNum.setTextColor(R.color.text_grey);
setBirthdayButton.setText("Date");
setBirthdayButton.setTextColor(R.color.text_grey);
}
Well my main problem is that i want to reset my text areas to hints not text…But i am not able to do so…. the text areas only get reset if i do setText…….
But i cant reset my text areas to hints .
So plz guys help me figure out whats the problem with the hints……..
set the text to
""in that way the user will see the hints (hints are gone if the text different then “”)
edit: