I am using android Tabbed Activity with 3 tabs. Each tab contains a fragment. I am trying to call Camera Intent from the 3rd tab using startActivityForResult(x, y); After I click the pic, the control returns to the activity, but not to the fragment which called the intent. I tried switching to the desired tab from onActivityResult() method in the activity, only to realize that it is not being called either. How Do I pass on the controls and intent to the desired fragment?
Asked
Active
Viewed 64 times
0
-
Have you tried to resume the desired fragment in `onResume`? – Michael Lam Oct 04 '18 at 09:19
-
Yes, I did that as well, but it always goes back to the default fragment – Tasnim Khan Oct 04 '18 at 15:17
-
Are you using `FragmentPagerAdapter`? – Michael Lam Oct 05 '18 at 01:25
-
@MichaelLam Yes, I am. – Tasnim Khan Oct 08 '18 at 20:53