[Solved]How could I include new jar file on android?



  • I am trying to embed the ads of AppBucks into the android app but have no idea how to do it

    According to the website, I should place the MobileSDK.jar into the android-build/lib
    But the compiler would complaint that "package com.appbucks.sdk does not exist"
    when I include the package

    appBucksAdv.java

    @
    package adv;

    import com.appbucks.sdk.AppBucksAPI;

    import org.qtproject.qt5.android.bindings.QtApplication;
    import org.qtproject.qt5.android.bindings.QtActivity;

    import android.os.Bundle;

    public class appBucksAdv extends QtActivity
    {
    private static appBucksAdv m_instance;

    public appBucksAdv()
    {
        m_instance = this;
    }
    
    @Override
    public void onCreate(Bundle savedInstanceState)
    {
      super.onCreate(savedInstanceState);
    
      AppBucksAPI.initialize(this, "chartUnitConverter",
      1, "4444", false, null, null);
    }
    

    }
    @

    "source codes":https://github.com/stereomatchingkiss/blogCodes2/tree/master/androidTest



  • Find out the answer, I should put at the inside of the android folder.
    Create a libs library and drop the MobileSDK.jar into it but not the folder after builded.



  • It would be great if it so easy. But how do you include it and use the functions from .jar?



  • I have been looking for ways to use third party library but to no avail.
    Anybody now links that explain how to use the methods of a third party jar file


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.