Androidstudio How to import jar packages
Original address: http://jingyan.baidu.com/article/e6c8503c7190b7e54f1a1893.html
Androidstudio is very handy for developing Android APK, but many of its settings are not the same as eclipse. For example, to add a new jar to a project, there is no access to the Java compilation path in Androidsutdio, it is difficult to find the entry to add the jar. However, in a different way, it is convenient to add jars in the Androidsutdio.
Tools/Materials
- Android Studio
- A project that can be imported into Android studio
Method/Step
Click Start Androidstudio, after the start of the interface. (Transfer to project)
Copy the jar you need to add and paste it into the App--src--main--libs folder, and the Androidstudio project that you can run has a directory structure like this. You can see that although the jar has been copied and pasted, it has not yet been imported, so the contents contained in the jar are not visible. Import jar, you can see the contents of the jar.
Right click on the new sticky jar and click on the add as Library in the pop-up menu.
Select the module you want to import into (equivalent to project in Eclipse in Androidstudio), and if it's just a project, there's nothing else in the dropdown box except the app, then click OK to confirm.
This allows the jar to be added to the project.
Adroid I'm still a rookie--Import the jar package