错误:(18,0)找不到参数的方法android()

时间:2016-09-08 10:43:23

标签: java android

我是Android应用程序的新手,我导入了一个应用程序,我得到这个错误,不知道该怎么做......有人在这里可以帮助我! 有我的build.gradle文件

buildscript {
repositories {
    jcenter()
}
dependencies {
    classpath 'com.android.tools.build:gradle:2.1.3'

    // NOTE: Do not place your application dependencies here; they belong
    // in the individual module build.gradle files
}
}
 allprojects {
   repositories {
    jcenter()
        }
        }

     android {
       compileSdkVersion 23
          buildToolsVersion "23.0.0 rc3"
                }

并且有我的app / build.gradle

apply plugin: 'com.android.application'

 android {
 compileSdkVersion 22
 buildToolsVersion "23.0.0 rc3"

 defaultConfig {
    applicationId "com.codeandcoder.finalguide"
    minSdkVersion 15
    targetSdkVersion 22
    versionCode 2
    versionName "1.1"
   }
   buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
     }
      }
       }

     dependencies {
     compile fileTree(dir: 'libs', include: ['*.jar'])
     compile 'com.google.android.gms:play-services:7.5.0'
    compile 'com.android.support:appcompat-v7:22.2.1'
        }

1 个答案:

答案 0 :(得分:0)

移动它:

android {
    compileSdkVersion 22
    buildToolsVersion "23.0.0 rc3"
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.google.android.gms:play-services:7.5.0'
    compile 'com.android.support:appcompat-v7:22.2.1'
}

module/build.gradle