2

I was following this tutorial: https://developers.google.com/chrome/mobile/docs/webview/gettingstarted and I wanted to generate the .apk so I could test it on my android phone.

I read here on stack overflow that to export the project to an apk we should go to Build > Generate Signed APK but I get the following error:

java.lang.UnsupportedOperationException

So I can't get my APK. Can anybody Help me with this problem?

  • Can you run your application on an Emulator? – Supreethks Feb 20 '14 at 13:34
  • No, I get this error: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.(myAplicationName).app/com.example.(myAplicationName).app.MainActivity}: java.lang.NullPointerException –  Feb 20 '14 at 13:38
  • Then you have a problem in your code. Check the stacktrace to see which line in your application is crashing the app. Also try Project > clean on eclipse before exporting apk. – Supreethks Feb 20 '14 at 13:42
  • For generating the Signed apk you need to specify the certificate configuration in release buildType inside build.gradle file. Have you done that? Please include your build.gradle file and project structure in question so one can answer. – Piyush Agarwal Feb 20 '14 at 14:29
  • You don't need to go through that signing flow until you're ready to publish your app to Google Play; for testing dev builds, you can use the "Run app" button in the toolbar. Even these builds are signed, by the way -- it just uses a default debug key instead of the developer key you need to set up for the Generate Signed APK flow. – Scott Barta Feb 20 '14 at 16:54

0 Answers0