0

I am trying to export a Signed APK to submit to the play store but when I click Build->Generate Signed APK that option is grayed out and I can not select it.enter image description here

Alex Borsody
  • 1,480
  • 8
  • 35
  • 72

4 Answers4

5

Synchronising the project seemed to have solved the issue for me:

File > Synchronize

Igor N
  • 373
  • 2
  • 5
3

Have you tried checking your project structure has an Android facet? Look under

File > Project Structure > Project Settings > Facets

This was missing for my project and prevented it from building.

Andrew Wyld
  • 6,923
  • 6
  • 49
  • 95
1

I'm not sure why this is happening, but as a workaround you could use gradle build tasks.

I generally do all this from the command line. If you don't have any build flavors, try doing the following:

./gradlew assembleRelease

You can see multiple ways to sign your build using this process here: How to create a release signed apk file using Gradle?

Community
  • 1
  • 1
loeschg
  • 28,353
  • 25
  • 89
  • 143
0

I am finding in the latest versions of Android Studio the File > Project Structure > Project Settings > Facets path does not exist.

To reach Facets do this:

On your Project tree click on the upper most element, the Project itself. Then right mouse to expose the menu item Open Module Settings.

There you will find:

Project Structure Window with Facets

Once you are there then I was successful in enabling the "Generate Signed APK" Build Menu item by adding the facets as shown below:

Facets that worked for me building a Flutter app

My apologies for the external links to the images, I don't have enough reputation points yet.

E.Bradford
  • 496
  • 3
  • 14