Android XML:&Quot;与具有相同ID&Quot;的另一个标记冲突

Android XML: quot;conflicts with another tag that has the same IDquot;(Android XML:Quot;与具有相同IDQuot;的另一个标记冲突)
本文介绍了Android XML:&Quot;与具有相同ID&Quot;的另一个标记冲突的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近从我的项目中删除了一个片段,包括它的布局和视图模型。(FragmentAddFlight,VmAddFlight,FragmentAddFlight_flight.xml)

令人惊讶的是,我收到以下错误:

    [databinding] {"msg":"u003cImageView idu003du0027@+id/imageView2u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":277,"col0":20,"line1":286,"col1":85}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView4u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":308,"col0":28,"line1":312,"col1":64}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/editText8u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":314,"col0":28,"line1":318,"col1":60}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView5u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":327,"col0":28,"line1":331,"col1":63}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView14u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":333,"col0":28,"line1":338,"col1":57}]}
  [databinding] {"msg":"u003cImageView idu003du0027@+id/imageView2u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":369,"col0":20,"line1":378,"col1":72}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView4u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":400,"col0":28,"line1":404,"col1":60}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/editText8u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":406,"col0":28,"line1":410,"col1":60}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView5u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":419,"col0":28,"line1":423,"col1":71}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView14u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":425,"col0":28,"line1":430,"col1":57}]}
  [databinding] {"msg":"u003cImageView idu003du0027@+id/imageView2u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":452,"col0":20,"line1":461,"col1":77}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView4u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":483,"col0":28,"line1":487,"col1":60}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/editText8u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":489,"col0":28,"line1":493,"col1":60}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView5u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":502,"col0":28,"line1":506,"col1":71}]}
  [databinding] {"msg":"u003cTextView idu003du0027@+id/textView14u0027u003e conflicts with another tag that has the same ID","file":"C:\Users\Christoph\Documents\Android-Projekte\FlightLogger\app\src\main\res\layout\fragment_add_flight.xml","pos":[{"line0":508,"col0":28,"line1":513,"col1":57}]}
请记住,这些错误中引用的文件已被删除。为什么我会收到这些错误?

我通过Build->Clean Project清理了该项目。我试着通过同样的菜单重建这个项目。但结果保持不变。

有人知道如何解决这个问题吗?

推荐答案

这些文件是在编译时创建的,因此它们可能没有被删除,请尝试在Android Studio中失效缓存并重新启动。

这篇关于Android XML:&Quot;与具有相同ID&Quot;的另一个标记冲突的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

How to target newer versions in .gitlab-ci.yml using auto devops (java 11 instead of 8 and Android 31 instead of 29)(如何在.gitlab-ci.yml中使用自动开发工具(Java 11而不是8,Android 31而不是29)瞄准较新的版本)
Android + coreLibraryDesugaring: which Java 11 APIs can I expect to work?(Android+core LibraryDesugering:我可以期待哪些Java 11API能够工作?)
How to render something in an if statement React Native(如何在If语句中呈现某些内容Reaction Native)
How can I sync two flatList scroll position in react native(如何在本机Reaction中同步两个平面列表滚动位置)
Using Firebase Firestore in offline only mode(在仅脱机模式下使用Firebase FiRestore)
Crash on Google Play Pre-Launch Report: java.lang.NoSuchMethodError(Google Play发布前崩溃报告:java.lang.NoSuchMethodError)