FindViewById() not finding View

前端 未结 6 1739
青春惊慌失措
青春惊慌失措 2020-12-06 12:09

Just added a new button to my already-working-fine layout, but the findViewById function seems to be angry with something I don\'t get to understand.

Here\'s a bit o

6条回答
  •  一整个雨季
    2020-12-06 12:45

    Some times the file R is not regenetated. Try :

    • Clean your project
    • Rebuild it
    • Manage to go back to a version that compiled and retry adding your elements one by one and compile each time to check the R file
    • Finnally the last option is to close/reopen eclipse yep some bugs can't be overcome other way ^^"

    No worry that's is just some common eclipse/android bug it happen often (Well some other times it can also be a small syntax error somewhere in your project but i assume that you already checked that x)

    Good luck

提交回复
热议问题