0
点赞
收藏
分享

微信扫一扫

Android Studio 升级到3.0后出现编译错误\.gradle\caches\transforms-1\files-1.1\*****-release.aar


最近Studio升级到3.0 后,新建一个项目,什么都没有添加就报错,烦都烦死了

错误日志如下:

C:\Users\Administrator\.gradle\caches\transforms-1\files-1.1\appcompat-v7-26.1.0.aar\6a8b09efde42f84982ba083742b4753d\res\values\values.xml

Error:(1050, 5) error: resource style/Widget.AppCompat.DrawerArrowToggle (aka com.wcyq.wolfmvvmdemo:style/Widget.AppCompat.DrawerArrowToggle) not found.

Error:(862, 5) error: resource style/Widget.AppCompat.DrawerArrowToggle (aka com.wcyq.wolfmvvmdemo:style/Widget.AppCompat.DrawerArrowToggle) not found.


百度了一通;

搜到了这两篇还可以的文章;

android.enableAapt2 = false

   在AS 的左上角 选择 -->File-->invalidated and Restart 一下

操作了,没解决我的问题.

一时间搞得很烦躁.后来自己改了下依赖版本号,结果就好了,操

没改之前; 这个是studio自动生成的.

dependencies {  
    implementation fileTree(dir: 'libs', include: ['*.jar'])  
    implementation 'com.android.support:appcompat-<span style="color:#ff0000;">v7:26.+'</span>  
    implementation 'com.android.support.constraint:constraint-layout:1.0.2'  
    testImplementation 'junit:junit:4.12'  
    androidTestImplementation 'com.android.support.test:runner:1.0.1'  
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'  
}

改了之后;

dependencies {  
    implementation fileTree(dir: 'libs', include: ['*.jar'])  
    implementation 'com.android.support:appcompat-v<span style="background-color:rgb(255,0,0);">7:25.+</span>'  
    implementation 'com.android.support.constraint:constraint-layout:1.0.2'  
    testImplementation 'junit:junit:4.12'  
    androidTestImplementation 'com.android.support.test:runner:1.0.1'  
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'  
}

 程序能跑起来了.真是毙了狗了,studio一升级,尽是些狗屁问题,建议没有升级的还是不要升级这些新版本,问题搞的头大!

举报

相关推荐

0 条评论