When I have to call MyStore.RequestPayment, I currently call it on the NoAds button and after closing the application and opening it again it asks me for the user's ID, the restore button works fine.
Private Sub B4XPage_Created (Root1 As B4XView)
'https://www.b4x.com/android/forum/threads/istore-in-app-purchases.49301/#content
MyStore.Initialize("MyStore")
If MyStore.CanMakePayments = False Then
m02_Views.MensajeToast(Root, "Error starting billing process")
End If
End Sub
Sub btnRemoveAds
MyStore.RequestPayment(vp.ADS_SDK_ID_GuardarEsquema)
End Sub
Do I have to save the value of the purchase result?, like this:
Sub MyStore_PurchaseCompleted (Success As Boolean, Product As Purchase)
kvs.Put("no_ads", Success)
End Sub
What happens if you return the purchase?, how do I change the value of the variable?