You get these errors because you did not import the licensing library.
Go to the folder where you downloaded the android-sdks file.
So, there are 2 things: I) Licensing Library and II) Trial Licensing Application
I) The licensing library is located in:
UserName / Android-SDKs / Advanced / Google / play_licensing / Library
II) An example licensing application is located in:
Username / android-sdks / optional / google / play_licensing / sample
OR
In Eclipse, File-> New β Other ... β Android Sample Project β (select a target and click next) β Google Play Licensing Library
Step 1:
In Eclipse, go to File-> New β Other ... β Android Project from the existing code β (find the library, i.e. = username / android-sdks / extras / google / play_licensing / library)
Step 2:
After you import the library into Eclipse, right-click on the package and go to Properties β Android. Make sure the "Is the library" checkbox is selected.
Step 3:
In Eclipse, File-> New β Other ... β Android Sample Project β (select a target and click next) β Google Play licensing library. By default, my package was named "play_licensing_sample".
Step 4:
Right-click on "play_licensing_sample" and go to "Properties" β Android β Add ... β (select the licensing library u in step 2) β Apply
You did it!
Gene
source share