[enter image description here][1]
Hello everyone I am not getting this option .get Text() when I write it is showing wrong in android studio please help help
[1]: https://i.stack.imgur.com/UF227.png
2
Answers
Your
Emailbox
is of type View:The View class in Android, doesn’t have any
getText()
methods, hence that error. So most likely your field should be defined of type EditText:private EditText Emailbox;
As the other fields are, and not as a View.
P.S. All elements in Android are views, meaning that each class extends the View class.
You can use EditText instead of View.
To get text programmatically using getText() method