-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
onActivityResult not called inside of Fragment #55
Comments
@YudizMohitS - When calling startPayUMoneyFlow(), don't use activity context and just pass this. |
@Rahul-Hooda Thanks. for your reply but this is not work with Fragment I am using this lib implementation 'com.payumoney.sdkui:plug-n-play:1.6.1' |
@YudizMohitS - You must be calling below integration function from your code - // Invoke the following function to open the checkout page. Now, when calling this from Activity, you can pass this which will pass activity context. In your case, you are calling it from inside a fragment. Please make sure to pass your fragment context and you shouldn't pass getActivity() in this. |
@Rahul-Hooda How can I pass this inside of Fragment because there is an Activity context in startPayUMoneyFlow method. |
@YudizMohitS - Yes. Activity context is consumed by the method. In this case, onActivityResult() of your activity will be called. From there you can consume the result. |
@Rahul-Hooda But my question is there is any way to handle inside of Fragment? |
@YudizMohitS - No, You can not handle it inside Fragment. The only way to handle it is through the Activity's onActivityResult() |
Is there any way to get a callback from Fragment?
The text was updated successfully, but these errors were encountered: