Shreyash Mahajan
Shreyash Mahajan

Reputation: 23606

Not able to import the another project as a library?

I am going to licensing my Application. I know all the process for licensing application. But for that I have to load the Library Project in My Workspace. I have loaded the Library Project in my WorkSpace then i have imported it into my Original project. It works great.

But now the problem is, If i have once deleted that library project and then if i have imported into workspace from another location and if i import it in to my that project then it is not going to import it.

And if i Import it from the previour one location, then its again works fine. . . So why it is happening like that?

Why i am not able to import the library project from any location?

Please guide me for this. Thanks.

Upvotes: 2

Views: 2245

Answers (3)

Paresh Mayani
Paresh Mayani

Reputation: 128448

From your question, i am assuming that you want to import any library into your project and if you want to use any library(.jar) then you can do these steps:

  1. create "libs" folder inside your application's structure, at same level of "src" directory.
  2. Now copy those libraries into this libs folder.
  3. Right click on any librarary -> Build Path -> Add to Build Path.

Update: As you have commented below as its library project, i would suggest you to go through this Android doc on Setting up a Library Project

Upvotes: 1

user644458
user644458

Reputation:

I dont know why it is happend. But if you have import once from any location. and then delete it. Now if you are imported the same project from another location than it is also not going to imported. For sollution you have to Put that library project at once place for which you what it every time. And if necessary then do not delete that library project after Importing it to the Original Project. Thanks.

Upvotes: 2

Lalit Poptani
Lalit Poptani

Reputation: 67296

If you want to include a project to your current project follow the steps,

1.) Right Click(or Alt+Enter) on the project_as_library->Library-> check mark Is Library

2.) Right Click(or Alt+Enter) on the project where you want to include the Library, go to Android->Library->Add. When you click Add you will see the Project name that you declared as Library, selected that and Press Ok and you are done.

Upvotes: 1

Related Questions