1

I am using Deep Link to interact with other app. For eample, I am doing UPI Payment using Deep Link. Say "A" is my App, I am choosing UPI supported app to do payment. Once the transaction is completed, My App "A" is recreated. Whatever the app state before transaction is lost. Is there any way to retain my app state when we do deep link? Please refer this link (UPI Payment Gateway using Android Deep Link) for deep link logic I have used.

I am using Paytm and Tez. this issue occurs only when I use Tez whereas its working fine if I use Paytm.

Manikandan
  • 673
  • 3
  • 12
  • 26
  • 1
    you need to do this on your own .. you can use sqlite to save the data and states in your own way and then recrete the app with that given data because user or os might kill your app .. if that is not the case then you can use saveinstance methods this link will help in that case https://stackoverflow.com/questions/151777/saving-android-activity-state-using-save-instance-state – Adeel Turk Mar 06 '18 at 12:56

1 Answers1

0

After going through the Android Activity Life Cycle, Its clear the Android System may destroy your app activity due to resource constraints when you switch over apps. I handled it by saving and restoring view state.

Manikandan
  • 673
  • 3
  • 12
  • 26