Import project in Android Studio from Eclipse

后端 未结 11 673
孤街浪徒
孤街浪徒 2021-01-01 10:06

I installed new Android Studio 0.1.1 based on IDEA ide and tried Import code from Eclipse.

  1. Go to Eclipse->Export->Grandle so it add gradle file
  2. Open A
相关标签:
11条回答
  • 2021-01-01 10:38

    Had the same problem when Android studio 0.2.9 on mac and importing an old eclipse project:

    By default, it uses /Applications/Android Studio.app/sdk as the android sdk location, instead of whatever you used to use.

    On a per-project basis, you can go to the menu's File->Project Structure (command-;) and on the left you can change the project's sdk location.

    To handle all projects (new or imported), before opening anything at the start screen click configure -> Project Defaults -> Project Structure -> (on the left) Android SDK to do the same. (re: https://stackoverflow.com/a/18409923/954643)

    If you were starting from scratch without any android sdk setup and eclipse though, you'd have to download the missing SDKs via Tools->Android->SDK Manager.

    0 讨论(0)
  • 2021-01-01 10:39

    These simple steps worked for me:

    1. Open new project (new not import)
    2. Press F4
    3. On the left Click on SDKs
    4. Delete all SDKs
    5. Click on +
    6. Choose the SDK you are using for eclipse
    7. Choose the right version
    8. Click OK
    9. Open your project using gradle file

    enter image description here Enjoy :)

    0 讨论(0)
  • 2021-01-01 10:39

    Do you have updated SDK for Eclipse? You need the Rev.22. After you downloaded it, you can Export the Project with a "build.gradle".

    Migration of the Projects

    Updating your SDK

    0 讨论(0)
  • 2021-01-01 10:39

    Update SDK go to config settings, project settings then you will see SDK that isn't correct point to same place eclipse points to for SDK. Worked for me.

    Also it might help to reexport the project with new sdk

    0 讨论(0)
  • 2021-01-01 10:41

    This is an import problem. NOT an SDK Level issue.

    You need version 22 of the SDK Manager before you attempt the export or it won't be in a format that Android Studio can consume.

    0 讨论(0)
提交回复
热议问题