问题
I have a problem with android studio. I'm developing a project where I have so many activities. But now, I've updated Android Studio to version 3.4 (April 2019) and I can't create a new activity. The ide doesn't show any error message, I press New> Empty Activity and I write the name of the activity and press 'Finish' but nothing happens in the layout. Does anybody know what kind of error it is? Thanks.



回答1:
open up the build at the bottom see if you get a hint.check if the directory path isn't too long or starts with smaller case(although doesn't affect but throws a suggestion)
回答2:
Umm i think you should try another method to make activity that is navigation graph. In navigation graph it is very easy to make new activity and manage them and it is a new features in android studio making your work fast.
To create navigation graph go to Project>res>Right click>New>Android Resource file> And then give any name and set Resource type to navigation.
It is very exiting and easy. See this website if you are interested: https://developer.android.com/guide/navigation/navigation-getting-started
回答3:
i had to face the same error when i was creating a new activity ,. we had to do what, we check the AndroidManifest.xml file and if there is an error then resolve it, after that you can able to create an new activity...try this at ones
来源:https://stackoverflow.com/questions/56104706/cannot-create-new-activity-android-studio