How to migrate the AndroidStudio project to the Eclipse project, eclipseandroid

Source: Internet
Author: User

How to migrate the AndroidStudio project to the Eclipse project, eclipseandroid

First of all, this is a very embarrassing topic. I have to confess to Google's efforts in developing the IDE. To be honest, AndroidStudio is much easier to use than Eclipse, but the project needs to be migrated.
Taking the FloatingAction project as an example
Note: you can slide up to hide the floating button and move up to display the floating button.
FloatingAction GitHub address: release demo, a lib project library
First, create a lib project and open the library folder to view the configuration file. Well, we use a maven-managed project. We don't need to worry about it. We don't need to use gradle or maven. Check AndroidManifest. xml.

OK. Find the package name com. telly. floatingaction and open the gradle. properties configuration file. Check that the lib project name FloatingAction Library does not care about what POM is. We do not need Maven. Create a project FloatingAction Library package in Eclipse named com. telly. floatingaction
Change the encoding format to UTF-8, maybe your default is to find the project path to src, res, AndroidManifest. replace all xml files. If there is a lib folder or jniLib folder, Copy the content to the libs folder and set the project to isLibrary.
Okay, an error is reported (it should not be an error ..) Android. support. annotation. * The resource does not have this problem because the Api requires a slightly higher version .. Only 21 is required. Just import the support package.
I did not find the Jar package on the Internet for a long time. I used AndroidStudio0.8 and found the Jar package in the SDK: http://download.csdn.net/download/liuyaoyue1/8063983import to go to OK.
R file loss, Refresh and Build again. If the problem persists, it is a problem in the Eclipse environment. For example, your Target version of tools has not been downloaded, change the Android version and try out my lib project.
The Demo project is as follows:
Like the lib project, check the configuration package name com. telly. floatingaction. demosrc, res, AndroidManefest. xml, replace the project references, and delete the xxxh resource file if the version is not enough.
OK migration is successful.
Android studio project importing android studio Project (not an eclipse Export Project)

Open build. gradle and check the content.
Buildscript {repositories {mavenCentral ()} dependencies {classpath 'com. android. tools. build: gradle: 0.7.0 '} apply plugin: 'android' android {compileSdkVersion 19 buildToolsVersion "19.0.0 "}

How to transfer projects on Android Studio to mobile phones

First, ensure that the red parts of the two configuration files are consistent. Android studio automatically downloads the gradlepackage.
Second, because the latest version of AndroidStudio does not support gradle1.6, if the two configuration file versions generated by Eclipse are too old, manually change them to the new version.
Third, make sure that AndroidStudio provides the following SDK versions. You can also change the version number in the configuration file to the version supported by AndroidStudio.
Android {
CompileSdkVersion 19
BuildToolsVersion "19.0.0"
In this way, the migration can be successful.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.