Import eclipse project to Android studio – error “this project refers to Eclipse workspace…”

I tried to import an existing project eclipse to Android Studio, but I got a dialog message in import that I can’t solve : “this project refers to Eclipse workspace relative path in its project metadata. To help import the project, please point to an Eclipse workspace directory.”

please check screenshots

  • W/IInputConnectionWrapper(1066): showStatusIcon on inactive InputConnection
  • android lollipop scrollview edge effect color
  • “Calling this from your main thread can lead to deadlock and/or ANRs while getting accesToken” from GoogleAuthUtil(Google Plus integration in Android)
  • android:inputType=“textEmailAddress” - '@' key and a '.com' key?
  • How to catch a “Done” key press from the soft keyboard
  • Extracting Data from pdf417 such as Drivers License
  • enter image description here
    enter image description here

    How I can solve it?

    Thanks so much in advance

    Related posts:

    How to keep an IntentService running even when app is closed?
    difference between MICRO_KIND and MINI_KIND in mediastore in android?
    Creating Compound Controls With Custom XML Attributes
    android Maps API v2 with custom markers
    Animate Two Layer Drawable Items Pre-Honeycomb
    Check for Active internet connection Android
  • How to use the token returned by GoogleAuthUtil.getToken with my App Engine backend
  • Android listview row delete animation
  • How to set Java SDK path in AndroidStudio?
  • Try to fetch bitmap from uri using Fresco
  • Convert ArrayList to String array in Android
  • Detect swipe gesture in fragment
  • 6 Solutions collect form web for “Import eclipse project to Android studio – error “this project refers to Eclipse workspace…””

    Simply delete all the folders and files from your project except manifest res,src and then import it in Android studio using Import from eclipse

    I have same error. Let me explain all steps. You have Eclipse project and you want to import in Android Studio. So when you try to import it it will ask you to generate project at different location as shown below.

    Import Eclipse project

    when you click on next it will show you this screen.

    Replace all libraries

    after proceeding you will get this screen.

    enter image description here

    now the question is why it ask for Eclipse workspace path?

    Answer: There is hidden .classpath file in your Eclipse project. the .classpath file contains information that the JDT feature needs in order to properly compile the project: the project’s source folders (that is, what to compile); the output folders (where to compile to); and classpath entries (such as other projects in the workspace, arbitrary JAR files on the file system, and so forth).

    First you have to select original Eclipse project path in Eclipse workspace path then you need to edit all file paths which is shown list. File names which are mentioned on left are already existed in original Eclipse project you have to set path so Android Studio will able to import project.

    I have solved by this approach. Please let me know if you get any other error.

    There is another way.You can create new project in android studio and add all the files like java files in java folder and replace res files.If there is any library ,import those library as well.Now you are ready to work in android studio.

    I have tried this when the same error occurs to me.

    First of all please make sure that you have done all steps in proper manner as provided here, the migration guide for projects in Eclipse/ADT

    As you can see from migration guide the Migration Prerequisites

    carefully see In Eclipse ADT section there they have already told this.

    It may be useful to record your workspace directory, path variables, and any actual path maps that could be used to specify any unresolved relative paths, path variables, and linked resource references. Android Studio allows you to manually specify any unresolved paths during the import process

    This answer have some best explaination of steps and the same question have other answers with pretty good picture representation.

    since i have seen this same problem you have in this specific answer the guy mentioned same problem and he tried again and successfully imported project. So you can Configure your build as @AR.3 mentioned in his answer. But i still want you to check that you have followed all steps perfectly because in most cases it shouldn’t happen. You can try to browse your specific prject from your eclipse workspace and see whats happen.

    Try to export project from eclipse or add module from android studio. May be its takes your old dir paths. May be it helps you.

    I dont know the exact cause and criteria that causes this but, it has to do with External Libraries Studio does not recoginze. I have found a very hacky solution that has served my purpose. It is not a total solution but it is the best i can offer to gracefully allow importing all sources

    1. Always back up your Data
    2. In the eclipse project Remove all external libraries via project properties-> java build path
    3. Close the project and import into studio
    4. Either Find compatible repo’s with gradle or
    5. add your previous external libraries .jar,.aar in the libs folder
    6. point gradle to said folder and files
      compile fileTree(dir: ‘libs’, include: ‘mylib-*.jar’)

    Like i said its a hacky work around but does the trick.

    Android Babe is a Google Android Fan, All about Android Phones, Android Wear, Android Dev and Android Games Apps and so on.