R.java file not updating with UI element's id

前端 未结 8 808
长情又很酷
长情又很酷 2021-01-04 02:03

I added some UI elements to the main.xml file in the res\\layout folder and when I try to access them through the call, R.layout.my_uielement, the UI element th

8条回答
  •  甜味超标
    2021-01-04 02:42

    I faced this problem too. The R.java was neither generated nor updated.

    If R.java is not generated when you create the project, run your 'empty` project. An R.java with references to resources will be automatically generated.

    If R.java is not getting updated, Check for updates in Help -> Check for Updates in Eclipse and update your SDK and ADT if required.

提交回复
热议问题