pty115 pty115 - 1 year ago 164
Android Question

google maps api sdk version error?

It's my code sample. When I firstly build my code, it results in so-called dex error. I added multiDexEnabled property to my gradle setting, but it results in java heap memory overflow. I increased its max size, and finally got builded. However, another error occurred...... what is the problem? android adk version?

apply plugin: ''

android {
compileSdkVersion 24
buildToolsVersion "24.0.2"

defaultConfig {
applicationId "belobster.earthquakealert"
minSdkVersion 14
targetSdkVersion 24
versionCode 1
versionName "1.0"
multiDexEnabled true
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), ''
dexOptions {
javaMaxHeapSize "2g"

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile ''
compile ''

emulator image.

genymotion emulator displaying google maps error

Answer Source

Check whether play services is available on the emulator, you should consider using physical device for these kind of testing purposes since maps require location services quite often.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download