Android Studio 布局错误:未知属性 [英] Android Studio layout Error : Unknown attribute

查看:29
本文介绍了Android Studio 布局错误:未知属性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Android Studio Code Completion 似乎不适用于 xml,并且除了 Android 支持 v7 视图的 attrs 之外,它也无法识别任何 xml 属性.截图:

Android Studio Code Completion seems not working on xml and also it doesn't recognize any xml attribute except the attrs on Android support v7 views. Screenshot:

我来自 android.support.design.v7 的视图正确显示:

my views that is from android.support.design.v7 display correctly:

推荐答案

如果你是 Android Studio 然后去 tools 然后 Android 然后点击 build with gradle,它会解决这个错误.我也遇到过.

If you are Android Studio then go to tools and then Android then click on build with gradle, it will solve the error. I encountered it too.

工具->Android->使用 Gradle 构建

Tools->Android->Build with Gradle

这篇关于Android Studio 布局错误:未知属性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆