How to solve “Your APK's version code needs to be higher than 2.” in Google Play's Developer Console?

后端 未结 16 682
半阙折子戏
半阙折子戏 2020-12-08 09:28

I\'m getting this error when uploading my Phonegap app to the Google Play Developer Console:

Your APK\'s version code needs to be higher than 2.

<
16条回答
  •  执笔经年
    2020-12-08 10:02

    Had the same problem and solved it by changing the following values in the build.gradle file in the Module: app

    defaultConfig {
            applicationId //app package goes here
            minSdkVersion 10
            targetSdkVersion 21
            **versionCode 2
            versionName "1.1"**
            signingConfig //name of keystore goes here
        }
    

    This is the way Android Studio keeps track of the versioning for each app.

    Alternatively, for the noobs, you can access these settings by clicking on the settings of the app, and navigating to the Flavors tab. There you can amend certain settings such as the versionCode and the versionName.

    Hope this helps :)

提交回复
热议问题