I'm using Android Studio and I've never imported or referenced any external libraries before.
The library I'm trying to reference is this: https://code.google.com/p/afiledialog/
I went to File - Project Structure - Modules and added a new Module pointing to this project library. After that I have no idea how to get it to work in my app, and when following the basic info on the main page it asks me to add this to my manifest file:
<activity android:name="ar.com.daidalos.afiledialog.FileChooserActivity" />
However when I do that it reports that it cant find the package FileChooserActivity.
All help is appreciated.
EDIT: Here are the main errors:
Gradle: package ar.com.daidalos.afiledialog does not exist
Gradle: cannot find symbol class FileChooserDialog
Gradle: cannot find symbol class FileChooserDialog
Navigate to File > Project Structure > Dependencies. In the Declared Dependencies tab, click and select Library Dependency in the dropdown. In the Add Library Dependency dialog, use the search box to find the library to add.
Select your project then go to Refactor -> Copy... . Android Studio will ask you the new name and where you want to copy the project. Provide the same. After the copying is done, open your new project in Android Studio.
Just go to Maven central and download the libraries. For example, here is Volley. Just click the download JAR button. I would strongly recommend sticking with Gradle / Maven, though, to keep consistency with versions and appropriately handle additional dependencies for the libraries you want to download.
How to find the libs folder in Android Studio? If you are unable to find the libs folder in Android studio then open your android project in “Project” mode If the project is already opened in the “Android” mode. Then go to Your Project Name > app > libs and right-click on it and paste the downloaded JAR files.
Go back to Project Structure
window where you added the new module. Click on your main module, go to Dependencies
tab, click the plus icon and select Module Dependency
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With