Monday, 10 October 2016

How to import a library project in Android Studio?

In this short tutorial I would show you how to import a library project in Android Studio v1.2.1.1. The steps to do so are:
  1. Goto File -> New -> Import Module.Android Studio Add Library
  2. Source Directory -> Browse the project path.
  3. Specify the Module Name – it is used for internal project reference.Android Studio Add Library - 2
  4. Let Android Studio build the project.
  5. Open build.gradle (Module:app) file.
  6. Add the following line with your module name in place of “Volley” in the dependencies block:
  7. It should look something like this:Android Studio Add Library 3
  8. After this Android Studio would start saying “gradle files have changed since last project sync”, press the “sync now” link to start a sync.
  9. That’s all you need to do.

reference of 

No comments:

Post a Comment