解决gradle DSL method not found: android()问题
来源:互联网 发布:epson手机打印软件 编辑:程序博客网 时间:2024/06/02 05:25
将项目导入AS中,发现了这个问题,Google之,按照下面这篇文章找到了解决方法。
I’ve been using Android Studio for about a year, since I started to learn how to develop mobile applications. For me, AS is way better than Eclipse: everything works so much better.
I used to download open source projects (mostly from GitHub) just to explore the code and learn, but since the release of the AS 1.0 RC version, the IDE can’t import correctly my projects — specially if they was created on Eclipse.
After update the general app configs (to the latest build tools and compile SDK version, for example) and try to compile and execute, I was getting the “gradle DSL method not found: android()” error. Very strange, since I reinstalled recently Android Studio and it’s supposed to come with the latest gradle.
After days searching about, I realised what the problem is and how easy is to solve it.
For a unknown reason, Android Studio incorrectly adds the android() method in the top-level build.gradle file.
Just delete the method.
//DELETE THIS LINES:
android { compileSdkVersion 21 buildToolsVersion '21.1.2'}
Try to compile again. It should work now.
- 解决Android Studio Gradle DSL method not found: 'android()'问题
- 解决Android Studio Gradle DSL method not found: 'android()'问题
- 解决gradle DSL method not found: android()
- 解决Gradle DSL method not found: ‘android()’
- 解决 Gradle DSL method not found: 'android()'
- 解决Gradle DSL method not found :'android()'
- 解决Gradle DSL method not found: ‘android()’
- 解决Gradle DSL method not found: ‘android()’
- 解决Gradle DSL method not found: ‘android()’
- 解决Gradle DSL method not found: ‘android()’
- 解决Gradle DSL method not found: ‘android()’
- 解决Gradle DSL method not found: ‘android()’
- 解决Gradle DSL method not found: ‘android()’
- Android:解决Gradle DSL method not found: 'runProguard()' 问题
- Android:解决Gradle DSL method not found: 'runProguard()' 问题
- Android:解决Gradle DSL method not found: 'runProguard()' 问题
- 解决gradle DSL method not found: android()问题
- Android:解决Gradle DSL method not found: 'runProguard()' 问题
- eclipse Mars查看JDK源码
- android 4.4源码下载——百度云盘地址
- 神经网络模型算法与生物神经网络的最新联系
- CentOS7——解压7z文件——p7zip
- The Struts dispatcher cannot be found. This is usually caused by using Struts tags without the assoc
- 解决gradle DSL method not found: android()问题
- cengos 安装redis 并将redis启动添加为系统服务
- Serialization Best Practices
- 配置Subversion SVN
- android—mm—mmm—没有规则可以创建target/product/generic/obj/SHARED_LIBRARIES
- Fedora 24 Will Use Wayland By Default, Fedora 24 Server Drops 32 Bit Support
- mm—mmm—android源码—编译
- 两种Domain Entity生成方式
- Category: Android——porting