Earlier last month, I posted an article describing what Android Studio is, and why you should consider moving to it at this stage for your Android Application Development needs. After posting that, I got a few messages asking me a guide to move their projects from Eclipse to Android Studio easily without spending too much time. I decided to write this small guide on how to move projects from Eclipse to Android Studio.
Recalling a bit, Android Studio is the official IDE for Android Application Development, provided by Google for easy application development. Earlier Google chose to support an Eclipse plugin which would make Android Development easy, but now they’ve come up with their own IDE. Android Studio boasts a lot of features that help us in developing better Android applications. If you haven’t read my earlier article, you should head over to that article first, and give it a read.
How to Move Android Projects from Eclipse to Android Studio in 3 easy steps
#1 Preparing for the move in Eclipse
This step is basically a starter step, which will make sure that your project is all set for a move into the Android Studio IDE. To do this, you need to make sure the following things:
- The project source code must be error free, there should not be a single error in any source code file for the project
- All the dependencies and external libraries for the project must be available/accessible in the system.
#2 Exporting your project for Android Studio
When you’re sure that your project has no errors and is ready to be moved to your newly set up Android Studio environment, select your project from the project explorer on the left. Then, right-click on your project and choose “Export”. Next, choose Android and finally choose “Generate Gradle Build Files” and click on Next. This will now export your project to your specified location.
#3 Importing your project in Android Studio
The last and final step in our move is to import the project in Android Studio. To do this, open up Android Studio and browse to File -> New -> Import Project. Next, browse for the folder you had exported in the previous step and choose import. If you had exported the project in the correct way, it will be imported into Android Studio at this point (within a few seconds).
Congratulations, you have successfully moved your Android Application project from Eclipse to Android Studio. If you face any problems regarding the move, do comment below on this post, and I would be happy to help you with any problems that you might be facing. Subscribe to Slash Coding’s Email Newsletter today so that you don’t miss out on any new articles that we publish every now and then. You should also follow us on Facebook and Twitter to stay updated.