B4J Question billing example and aar files

giggetto71

Active Member
Licensed User
Longtime User
HI
I am trying to go through the in app purchases example (https://www.b4x.com/android/forum/threads/googleplaybilling-in-app-purchases.109945/#content). I have copied the GooglePlayBilling library in the B4j Addritional library and also the file billing-3.0.1.aar. When I try to run the example "BillingExample" from the case, B4j complains that it

Cannot find: C:\Program Files (x86)\Anywhere Software\B4J\libraries\billing-3.0.1.aar.jar


I have tried to add the jar extension to the aar file but if I do so B4j still complains:

B4J line: 76
For Each p As Purchase In Purchases
javac 1.8.0_161
src\b4j\example\b4xmainpage.java:64: error: package com.android.billingclient.api does not exist
_p = (anywheresoftware.b4a.objects.BillingClientWrapper.PurchaseWrapper) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4a.objects.BillingClientWrapper.PurchaseWrapper(), (com.android.billingclient.api.Purchase)(group2.Get(index2)));
^
1 error



Can you please provide some guidance on how to run example? I guess the same would work for B4A as well..my idea was to first "study" how it works in B4J and then apply in B4A but so far I was not able to run the B4J example. Thanks for your help.
 

DonManfred

Expert
Licensed User
Longtime User
Can you please provide some guidance on how to run example?
It is an B4A Library calling Android methods.

Are you sure it does work with B4J too? I fear it is not compatible with B4J.

There is no such thing in B4J: AAR Files.
 
Upvote 0

giggetto71

Active Member
Licensed User
Longtime User
makes sense..I will try the B4A example. I just assumed it was working as I found the B4J example in the zip. Thanks as usual for your support.
 
Upvote 0
Top