I\'m trying to build an app, that pastes an input from a previous activity(works with no problem) and then shows me some things from a database(when ButtonGet is pressed). T
Problem is you first initialize textView1, and perform the button click, at that point you are just resetting any previous settings by calling onCreate() again, and before perfomClick methods hits getData() method, inside here also tries to access the text from textView1 but you called onCreate after that and set the view from scratch. That is why you cannot get it work, delete the duplicate code