Cannot run sample applications from demo for Android Studio.

Hello, I recently downloaded the demo for the Android SDK. In following the instructions for running the sample applications, I first tried to run the griddle.bat setupSamples to which i got the following errors.

./gradlew.bat setupSamples
./gradlew.bat: line 1: @if: command not found
./gradlew.bat: line 2: @rem: command not found
: command not found 3: @rem
./gradlew.bat: line 4: @rem: command not found
: command not found 5: @rem
./gradlew.bat: line 6: @rem: command not found
: command not found 7:
./gradlew.bat: line 8: @rem: command not found
./gradlew.bat: line 88: unexpected EOF while looking for matching `"'
./gradlew.bat: line 91: syntax error: unexpected end of file

Then I tried to open the projects in Android Studio. They opened fine with no errors.

When I tried to run them on a Nexus 9 tablet, I got the following crash immediately on launch:

06-29 09:25:11.712 4634-4634/? E/AndroidRuntime﹕ FATAL EXCEPTION: main
    Process: com.pdftron.pdfnet.demo.pdfviewctrl.debug, PID: 4634
    java.lang.ExceptionInInitializerError: UnsatisfiedLinkError: Couldn't load PDFNetC: findLibrary returned null. Expected arm or x86 or arm64, found cpu_info: abi: arm64-v8a
    processor : nvidia denver 1.0 rev 0 (aarch64)
    processor : 0
    processor : 1
    features : fp asimd aes pmull sha1 sha2 crc32
    cpu implementer : 0x4e
    cpu architecture: aarch64
    cpu variant : 0x0
    cpu part : 0x000
    cpu revision : 0
    hardware : flounder
    revision : 0000
    serial : 0000000000000000
    mts version : 33410787
            at pdftron.PDF.PDFNet.<clinit>(SourceFile:122)
            at com.pdftron.pdfnet.demo.pdfviewctrl.PDFViewCtrlDemo.onCreate(
            at android.os.Handler.dispatchMessage(
            at android.os.Looper.loop(
            at java.lang.reflect.Method.invoke(Native Method)
            at java.lang.reflect.Method.invoke(

and when I try to run it on a Nexus 9 simulator

Unable to identify the apk for variant arm-debug and device Nexus_9_API_22_-_BBI [emulator-5554]

Any insight would be fantastic, as I assume my demo version is on a time limit and I would like to test out the product.


If you are still having problems, let us know what the latest error message is that you got.

Also, make sure you are on the latest version of Android, in case there was a fix. Otherwise, solving the setupSamples error would be the first step.