Android Studio cannot resolve R in imported project?

后端 未结 30 2262
名媛妹妹
名媛妹妹 2020-11-30 02:27

I\'m trying the new Android Studio. I\'ve exported a project from eclipse, using the build gradle option. I\'ve then imported it in Android Studio. The R.java file under gen

30条回答
  •  Happy的楠姐
    2020-11-30 02:45

    Here's what worked for me in IntelliJ (Not Studio), in addition to the replies presented above:

    You need to attach an Android facet to an existing Android module. To do this, select the module from the module list in 'Module Settings', hit the '+' button on top and select 'Android'. See https://www.jetbrains.com/idea/webhelp/enabling-android-support.html.

提交回复
热议问题