how to call onActivityResult in cordova ionic app

692 views Asked by At

Any wrapper class available for onActivityResult in cordova/Ionic app. Needs for UPI deep linking response. Is any UPI common library available for ionic/cordova app. Following http://www.npci.org.in/documents/UPI-Linking-Specs-ver-1.1_draft.pdf

1

There are 1 answers

1
David On

You can use onActivityResult() in a cordova plugin like this:

E.g. in your execute method:

cordova.setActivityResultCallback(this);
cordova.getActivity().startActivityForResult(intent);

And the corresponding method:

@Override
public void onActivityResult(...) {
    super.onActivityResult(...);
}