java.lang.NoSuchMethodError: No static method getFont(Landroid/content/Context;ILandroid/util/Typ...

java.lang.NoSuchMethodError: No static method getFont(Landroid/content/Context;ILandroid/util/TypedValue;ILandroid/widget/TextView;)Landroid/graphics/Typeface; in class Landroid/support/v4/content/res/ResourcesCompat; or its super classes (declaration of 'android.support.v4.content.res.ResourcesCompat' appears in /data/app/com.m.testgoogle-2/base.apk:classes2.dex)
at android.support.v7.widget.TintTypedArray.getFont(TintTypedArray.java:119)
Android Studio升级3.0后 新建项目
开始:
compileSdkVersion 26
targetSdkVersion 26
compile 'com.android.support:support-v4:26.+'
compile 'com.android.support:appcompat-v7:26.+'
compile 'com.android.support:recyclerview-v7:26.+'
compile 'com.android.support:design:26.+'
修改为
compileSdkVersion 27
targetSdkVersion 27
compile 'com.android.support:support-v4:27.+'
compile 'com.android.support:appcompat-v7:27.+'
compile 'com.android.support:recyclerview-v7:27.+'
compile 'com.android.support:design:27.+'
就解决了

依赖包冲突 clean rebuild之后也解决了,完全不知道原理。

©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

  • 博客原文链接 Android百大框架排行榜(转) 说明: 无聊写一篇笔记式文章. 精力有限,很多错误之处,受时间与...
    码农朱同学阅读 8,145评论 0 27
  • 请允许我借鉴前辈们的东西~~~~ 感激不尽~~~~~ 以下为Android 框架排行榜 么么哒~ Android...
    嗯_新阅读 6,780评论 3 32
  • 当item的数量过多,需要向下滑动显示时,程序就出错退出 搜索半天都没有看到一样的错误原因,今天看到一个说supp...
    AmeeLove阅读 9,533评论 1 2
  • 一.榜单介绍 排行榜包括四大类: 单一框架:仅提供路由、网络层、UI层、通信层或其他单一功能的框架 混合开发框架:...
    不务正业的程序猿阅读 4,903评论 0 6
  • 人是在什么样的状况会流泪 大概是到心坎的痛和失落 如果人生迷茫 眼泪大概是无助 如果人生离别 眼泪大概是旅途 如果...
    鬼暗阅读 3,034评论 16 10

友情链接更多精彩内容