Failed linking file resources

后端 未结 25 1008
悲&欢浪女
悲&欢浪女 2020-12-01 03:09

This is the java file that is giving the error

package com.example.daksh.timetable;

import android.support.v7.app.AppCompatActivity;
import         


        
相关标签:
25条回答
  • 2020-12-01 04:11

    It is a xml error for some reason may be because of deleting a view or string in another view or may be for missing " or /> ..... etc

    But here I am using a good technique to figure out where is the problem exactly :-

    • Go to every single xml file and minimize the root element if you find something like this so you got where is the error, fix it then repeat the process for all files.

    • If the file has an error you will see three dots with red color
    • Fix the error here I removed this line because this array is not in the string file any more.
    • Now you can see there is no error in this file any more if you still got the main error so you have to repeat this process again to all xml files until you solve the error

    I know it is not the solution of the main problem but it will make you find where is the error quickly and save you time.

    Update

    There is another way you can find out easily, as Bennik2000 write in comment, you can look at the right scrollbar for red lines, they also indicate errors.

    Update

    I found a very simple way to get where is the error exactly if it is in resource file or even java file.
    1- Go to Project Window.
    2- Open the file that has the error.
    3- Click F2 to go to the nearest error appears (it will go to the correct line)

    0 讨论(0)
提交回复
热议问题