0

I am trying to add the project https://github.com/passsy/android-HoloCircularProgressBar as a library to my project using android studio. I have added the project as a module and loaded it into the build.gradle file and added the dependency as well.

dependency {
     compile project(':HoloCircularProgressBar')
}

No matter what it won't be able to find the attr 'cicularProgressBarStyle' and even in the xml it says unable to locate class file.

Would appreciate any help on this matter.

Thank you.

ahmad
  • 2,149
  • 4
  • 21
  • 38
  • How have you added it as a library? – Scott Barta May 08 '14 at 17:26
  • File -> Import Module after that I went to Project Structure -> Modules and added the module. – ahmad May 08 '14 at 18:17
  • What version of Android Studio is this? I'm trying to reproduce in the latest and I'm having trouble getting it to import the library at all. There's also http://stackoverflow.com/questions/23351241/holocircularprogressbar-java-lang-nosuchfielderror-de-passsy-holocircularprogr but I wasn't able to figure out what was going wrong there either. See also http://stackoverflow.com/questions/20310164/how-to-import-eclipse-library-project-from-github-to-android-studio-project though that's for a very old version of Android Studio. – Scott Barta May 08 '14 at 18:34
  • android studio version 0.5.7 – ahmad May 08 '14 at 20:01

1 Answers1

1

To import this plugin in Android Studio, complete the following steps:

  1. Download the latest version of the plugin and extract the library directory (rename it if you want - I've called mine circularProgressBar)
  2. Create a new directory called libraries at the root of your project in Android Studio
  3. Put the previously extracted library directory into into the new libraries directory
  4. Go to your settings.gradle (also at the root of your project) and add the following: include ':libraries:circularProgressBar'
  5. Now go to File > Project Structure, select your module and click on the Dependencies tab, then click '+' and select 'Module Dependency'. You'll be prompted to select the holoCircularProgressBarModule. Select it and click OK.
  6. Do a Gradle Sync and the project should be successfully imported.

This was completed using Android Studio 0.5.8

HBG
  • 1,731
  • 2
  • 23
  • 35