Вопрос

I got a project and imported it in Eclipse (it is an android project). The project works on other computers, but unfortunately not on mine. The error which comes up is in the console of eclipse when i import the project: "Unable to resolve target 'android-8'"

Furthermore do i get multiple errors in on of the .java-files in the src folder of the project.

3 of them are showing "String cannot be resolved to type":

Here the code (It is for a music player the timer /showing of the seconds):

    /**
 * Function to convert milliseconds time to
 * Timer Format
 * Hours:Minutes:Seconds
 * */
public String milliSecondsToTimer(long milliseconds){
    String finalTimerString = "";
    String secondsString = "";

I hope you can help me!

Thank you so much in advance!

If you have any questions please let me know.

Thanks guys.

Cheers

Это было полезно?

Решение 2

It seems you have something set with a build target of API 8. Perhaps a subproject or library?

If that's intended then it sounds like you need to download Android 2.2 (API 8) through your Android SDK manager.

Другие советы

You'll be having project.properties file open that and change the android-8 to whatever android version you have. After changing this goto Window->Preferences->Android. You'll be having target name & api level. select any one of them & specify it in project.properties file.

Right click on the project, Properties -> Android -> Select the build target -> Apply -> OK

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top