Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialQingyu Meng
3,007 PointsCannot import parse to project on Android Studio
I have already add the Parse-1.5.1.jar to the libs, but when I try to import it, it cannot be resolved.
6 Answers
Gunjeet Hattar
14,483 PointsJust to be sure, did you include the .lib file as a dependancy by going into the module section of the project structure?
Eric De Wildt
Courses Plus Student 13,077 PointsYes the problem might consist in the build.gradle file.
Should look like this
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile files('libs/Parse-1.5.1.jar')
}
kylan hill
3,125 PointsTy Eric, I was having this problem
Susanna Remec
12,316 PointsI solved this puzzle by syncing the project with gradle files. The dependencies had added themselves but the sync was needed for the project to run. Just hit the button.
Noam Elbaz
5,672 PointsI found that you need to bring the entire unzipped Parse sdk into the "libs" and then right click and add to library on the parse and bolts file separately. And double check that gradle dependecies are there. NOTE: dont copy and paste above. you might have a different parse version than posted.
I ran the test data and every worked.
Andy Hammond
5,415 PointsI was so confused...then i just right clicked Parse-1.8.2.jar and "add as library" and clicked ok. This allowed me to import.
Oca Brown
5,633 PointsStill stuck on adding Parse.com to Android Studio , I have rebuilt the project, searched the internet for step-by-step instructions and come up empty. I am getting errors at just about every stage. I even searched for eclipse Android SDK to download and could not find it.
Eric De Wildt
Courses Plus Student 13,077 PointsPlease provide your gradle file for us to look at.
Oca Brown
5,633 PointsPlease see below
dependencies {
compile 'com.android.support:appcompat-v7:21.0.3'
compile files('src/main/libs/Parse-1.8.3.jar')
compile 'com.parse.bolts:bolts-android:1.+'
}