Error after updating Android Studio - android-studio

I have updated my Android Studio to 1.2.1.1 and now i am trying to create a new project and it shows an error:
"Error Loading Default Project "
Fatal error initializing 'com.intellij.openapi.vcs.changes.shelf.ShelveChangesManager'
Please suggest a solution. Thanks in advance

Experienced the same problem on Ubuntu/Linux.
In my case the solution was to change the save path of my project from relative, to absolute.
Trying to create a new project in ~/AndroidStudioProjects/MyApp would generate this error
But if I specified the full path /home/myusername/AndroidStudioProjects/MyApp, the problem was resolved.

You have to reset Android Studio and this is a configuration problem.
Uninstall android studio and install again.
This link will help you with all steps of reinstall.
Unable to create new android studio project?

I just came across the same error:
'com.intellij.openapi.vcs.changes.shelf.ShelveChangesManager'
Make sure that you have permissions to write to the project path.
android studio stores the project in the last location you loaded from and in my case it was a Flash Drive...
#Garima Mathur's answer suggests that is a 'configuration problem'
If it's a 'configuration problem' you can delete(*or better rename) the configuration folder.
which is located in the c:\users\CURRENT_USER\.AndroidStudio1.2
but in my case the solution was to change the path of the project to be saved.

I had the same error of "Error Loading Default Project"
Fatal error initializing
'com.intellij.openapi.vcs.changes.shelf.ShelveChangesManager'
and I figured out where the error was coming from. Previous I was running my project from a USB key labeled volume F. Later when I opened Android studio after unplugging, the default storage path was still F. Make sure your path is okay.

I also had the same problem. Following process worked fine for me:
Open your any old project in android studio.
Go to File > New > New Project.
Set Name to your Application.
At bottom of window there is "Project Location TextField".
Just change the Location Path to the desired folder and click Next Button.

I had the same issues, I tried to figure it by my self and it worked.
Try this, open your old project, then in your old project window, go to file > new > new project, and it will show the new project window to let you setup your project, after you finish your project setup, click finish and your project will start building and it will bring you to your new project window.
That's all, it works for me.

Related

Android Studio Clicking on "Project Structure " not working

I have met a strange question about Android Studio and I have tried to find a solution on the Internet but it failed.
Here is my question:
I open the Android Studio and the project can be installed to my device correctly. However, when I tried to open the Project Structure, it failed without any response. I just clicked on the button below but the Project Structure dialog didn't show up:
I have SDK installed below:
Please help me how to open the Project Structure dialog.
I have found a method to avoid my problem. My way is that uninstalling my sdk which version is Android 4.4. After doing that my project structure shows up. try deleting your current sdk for an attempt.

Android Studio is showing wrong project name

I have an Android Studio Project , the original name was GUI-refresh-by-time however it is showing Typer in the main screen.
But when I open the project, it becomes GUI-refresh-by-time
My .idea/.name is called "GUI-refresh-by-time"
How can I resolve this issue? It might lead confusion specially when you have too many projects.
Ok, I solve it anyway.
The problem occurs because I have another Android Studio project name
Typer , both of them are located in the same Folder Location root/Gui-GUI-refresh-by-time and root/Typer
Basically this root/Typer does not have .idea/.name so I decided to delete the Typer project Folder and reopen my Android Studio, after then it works.
you could just remove the project from the workplace by saving it elsewhere and try reimporting it

Android Studio : Unable to add a new class or any file to a project

My Android was working perfectly and was able to add a new xml,activity or any new file to my project. Until recently, it gives an error whenever I add a new class or any new file. It always says:
Unable to parse template "Class" Error message: Cannot modify a
read-only directory
'C:\Users\jay\Desktop\CurLoc\app\src\main\java\com\example\jay\curloc'.
I already tried to change the attribute of the folder where my project is located by unchecking Read-Only box in the Properties. I also restart my computer and Android Studio over and over again and refresh the project but nothing works. Please help.
After spending countless hours trying to solve the problem I uninstalled Android Studio and installed it again, this solved the problem. I think it's a bug in Android Studio

Project Name in Android Studio Does Not Change

I followed the instructions here Change project name on Android Studio and while my project name in the project explorer changed, the project name in the top IDE bar does not(the very top left of the IDE window). I renamed the project by right clicking the project name, updated the manifest's app_name and package name.
This is a bug where some pointers in the duplicate project still point to the original project. I experience this only when using "Open Project" to bring the duplicate up in AS. This is solved by using the "Import Project" instead and then refactoring and renaming accordingly.
This brings up another issue, however. While the naming is correct, something is still pointing to the original, because launching either the original or the duplicate on the device replaces the other on the home screen.
With Android Studio off, I renamed the project folder in Explorer and restarted Android Studio and imported project. Now this created another .iml in the project folder so I went ahead and deleted the old .iml .
(it seems to have correctly changed the app.iml in src also)
I hope this is all there is to it.
this work for me:
Close android studio
Change project root directory name
Open android studio
Open the project(not from local history but by browsing to it)

Android studio no main activity, no layouts on a new project

I installed new Android Studio. I created new Project and asked the wizard to create main activity. But there were no layouts, no main activity class, no nothing. Error on trying to make new Java class files. The new project tree looks like this:
No (main/java) folder.
No (res/layout) folder.
Other words project is useless.
From what i learned is that you may be picking the "no layout" option when prompted to pick one. Try picking the basic activity and the rest of the files will show
After creating the project, you need to go to File menu and then Import Project. Then browse to the location of your project and import it. Then you will see all of these files and folders. I had this problem too, and it seems to be something that they overlooked in the newer versions of Android Studio (which is quite pathetic if you ask me).
Empty Activity
Choose "Empty Activity" instead of "No Activity",
while creating a NEW PROJECT in Android Studio.
I don't know if anyone is having the same problem right now but i solved this issue by changing the Android Gradle plugin version and the Gradle version.
For doing this you have to open the project you're having issues with and click on
File->Project Structure->Project
and there you will see the two options.
Android Gradle Plugin Version 4.0.0 and Gradle version 6.1.1 worked for me. After that I went to the file directory, right click on the package folder "com.example.myProject" and manually created an empty activity. The layout folder with my new activity was created automatically after that.
I found it's because I changed the Java runtime version before through the Android Studio plugin Choose Runtime. I changed to JDK 8 from JDK 11 then the problem occured. It worked for me to change back to JDK 11 through plugin Choose Runtime.
Try
Typing main activity (without quotes) in the search box and
Press enter.
For me it got restored. Search window is useful in finding many hidden tools quickly.
I created a new activity by right clicking on java then selected activity and the layout file was automatically written
When you open a new project, you can't select "empty project" you have to select and activity project. I just went through this had to delete my project and start a new one now everythings there.

Resources