Android Question In-App Billing v3 - Can't add item to in-app products

jtare

Active Member
Licensed User
Longtime User
I just updated my app, exactly the same as the previous version but now with the In-App Billing v3 library checked as the tutorial suggested, but I can't add items to in-app products, play console says that I need to add "Billing permission to your APK".
What I am doing wrong? Maybe I should create a brand new app with a simple apk and the library checked?
I tried updating with out publishing and updating with publishing.
Almost 12 hours have passed since I updated the app in the console.
 

MarcoRome

Expert
Licensed User
Longtime User
I have not added the object, I thought that the tutorial mean to only check the library. Should I initialize it too?
Thanks.



Very useful, thanks!

Yes is necessary that you initialize it too..as in Tutorial you can see also this code:

B4X:
Sub Process_Globals
    'These global variables will be declared once when the application starts.
    'These variables can be accessed from all modules.
    Dim manager As BillingManager3
    Private key As String = "MIIBIjANBgkqXXXX......"
    Dim Productid1, Productid2 As String
    Dim Producttype As String
    Dim DeveloperPayload As String
    DeveloperPayload="Example In-App Consumable" ' ---> Name of my App "
    Producttype="inapp" ' ---> this is an input
    Productid1 = "price_300" ' ---> this is an input I it is the product id i defined in the store
    Productid2 = "price_500" ' ---> this is an input I it is the product id i defined in the store
End Sub
Sub Globals
    Private Button3 As Button
    Private Label2 As Label
    Private Button1 As Button
    Private Label1 As Label
End Sub
Sub Activity_Create(FirstTime As Boolean)
    If FirstTime = True Then
        manager.Initialize("manager", key) ' <--------------- HERE 
..................
    End If
 
Upvote 0
Top