Search code examples
androidandroid-studio

versionCode/versionName bug


I have this strange problem with my android studio, when I try to compile/run/build apk the androidCode and androidName always comes to version 1.0, no matter what I set it. I've been changing the main AndroidManifest.xml file, and still nothing. Does anyone else have this bug, or what have you done to fix it?


Solution

  • It was build.gradle being the culprit, under android, you need to change the settings here:

    defaultConfig {
        minSdkVersion 9
        targetSdkVersion 19
        versionCode 2 <----This
        versionName "1.1" <----This
    }