How to load resource from another package in xml?

偶尔善良 提交于 2019-12-03 21:22:30

Make your project a library project and you can refer it in another android project.

Library Projects

These projects contain shareable Android source code and resources that you can reference in Android projects. This is useful when you have common code that you want to reuse. Library projects cannot be installed onto a device, however, they are pulled into the .apk file at build time.

For more information have a look at the link under the topic Library Projects.

http://developer.android.com/tools/projects/index.html

Your library project will have a check box ticked as shown in the project.

You can add library project to your android project. Right click on your project. Goto properties. Choose Android on the left panel.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!