Wednesday, February 20, 2019

Could not find method versioncode () for arguments 1.1 on defaultconfig

This problem came, when I tried to upload an apk to playstore with version changes. Means, I launched my second version and got this error.

Solution:

Go to you build.gradle(app) and make changes like below. It will work.
minSdkVersion 15targetSdkVersion 26versionCode 2.0.toInteger() // This is what I changed
versionName "2.0"