I have a problem. When I start a new project in Android Studio and select a navigation drawer activity it happens. I don\'t have access to my activiy_main_drawer.xml
I've just run into the exact same problem. I simply solved it by choosing Sync Project with Gradle Files
. This will trigger a Gradle re-import and a build.
As of Android Studio v3.2, the icon is located near the top right tool bar. You can also find it using Find Action
shortcut CtrlShiftA.
I upgraded to AS 3.6 RC1 because of this time-waster but it still intermittently occurs!
Simply restarting AS has so far been working for me.
I've also faced this problem. The above solution wasn't worked for me.
I just restarted
my Android Studio
by closing the Android Studio application and opening it again from Start Menu. It works for me. Try this solution if the above not working. Hope this will helpful for you.
What worked for me was, from the top menu:
Build -> Clean
Build -> Rebuild Project
After that the xml design worked
In my case, I was using an alpha version of material design lib, and it was not able to render any view in the project. Solved by downgrading to a stable version.