Tuesday, July 31, 2012

"unable to resolve target" and "Unable to get system library for the project"

Have you even tried to import an Android Project into Eclipse, but get error like "unable to resolve target" and "Unable to get system library for the project" ? If so, this post may help.




 In sometimes, the error was caused by unavailable of certain Android SDK version. The project may be build based on a version of Android SDK, that your Eclipse had not installed.

To solve the issue, just following the steps below.

1. In Eclipse, right click your project > Properties.
2. Click Android, select a build target and "ok"
3, When you go back to Eclipse, clokc, Project > Clean > Clean all projects

Then back to your .java and all error should be removed.

p.s. The nice example was came from How to convert an Activity class to use with FragmentPagerAdapter

No comments:

Post a Comment