Reputation: 43
Well. My question is
I want to make the EditText
text the is insereted by the user to be a hint.
Thanks.
Upvotes: 0
Views: 146
Reputation: 2561
Use android:hint in your xml...like--
<EditText android:hint="Hello" />
set here watever hint you want to give
Upvotes: 0
Reputation: 3064
Try this...
EditText editText= (EditText) findViewById(R.id.edit_text);
String txt= editText.getText().toString();
editText.messageText.setHint(txt);
Hope this will help you.
Upvotes: 0
Reputation: 5162
I think that you want to do this
String text = edittext.getText();
edittext.setHint(text);
Upvotes: 1