In app billing android gives error -1005?

允我心安 提交于 2020-01-03 13:04:51

问题


I am going to implement managed in app billing in android I have tried a trivial sample application but when I run the app on a device it gives me error.

I don't understand what I am doing wrong and why this error occurred.

First display popup

when I click OK than it give me error on log.

Second display popup

06-23 14:37:04.912: E/Trivial Drive(19340): **** Trivial Drive Error: Error purchasing: IabResult: User canceled. (response: -1005:User cancelled)

回答1:


It is simple: Google Play In-app purchase testing is not so intuitive.

To test new IAPs you should upload a Beta version of your App (with all logic already implemented) and register some test accounts to download that Beta Version and test.

Every change you should upload a new Beta Version and the error wont appear anymore.

PS: To ensure the logic is working fine, you should use test billing IDs listed here: https://developer.android.com/google/play/billing/billing_testing.html



来源:https://stackoverflow.com/questions/24362796/in-app-billing-android-gives-error-1005

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!