OnAttach function deprecated. Replacement?

0 Rajani Krishna Turlapati · August 25, 2015
Hi,
In the fragments video, public void onAttach(Activity activity) is used to attach the fragments in the mainactivity. But this method is deprecated. What should I replace the code with?


Post a Reply

Replies

Oldest  Newest  Rating
0 Rajani Krishna Turlapati · August 28, 2015
Deprecated method is not creating any problem. I ran the code with that. The actual bug was with Onclick method inside the new View.OnClickListener(). Onclick is not overriden but written manually. When I pressed Alt insert overrode the onclick method, it ran.
  • 1

Java / Android Development

107,243 followers
About

Very popular language used to create desktop applications, website applets, and Android apps.

Links
Moderators
Bucky Roberts Administrator