Could not find method android() for arguments on root project '项目名' of type org.gradle.api.Project.

xiaoxiao2021-02-27  373

Could not find method Android() for arguments  [build_9m5ezt0p5zo7axieu78rb2u57$_run_closure2@3207872b] on root project ‘xx项目名xxx’ of type org.gradle.api.Project. Open File

解决方案:  添加:  apply plugin: ‘com.android.application’

其是可以理解为该 model 为一个 com.android.application 程序,  也就是应用程序,如果你的 Model 是一个库,那么自然也就是: 

apply plugin: ‘com.android.library’

转自http://blog.csdn.net/jyp123123/article/details/56484280

转载请注明原文地址: https://www.6miu.com/read-5329.html

最新回复(0)