Unable to resolve target 'android-XX'的問題解決

1.問題現象(Unable to resolve target 'android-XX')android

將低版本的代碼導入eclipse時,常遇到這樣的問題:Unable to resolve target 'android-XX'api

2.問題緣由eclipse

這是原代碼中project.properties 的 Project target 設置與當前eclipse環境設置不一致所致。3d

3.解決方法blog

首先獲取當前Eclipse的api版本,由下圖可知個人Eclipse的api版本爲20ip

 

而後進入android project即項目的根目錄,把project.properties文件用記事本(我用的UltraEdit)打開,將 Project target.target=android-8 改成你當前支持的api版本便可get

將紅圈中的api版本改成上述中查到的Eclipse的api版本,此處我修改成20,並保存。it

相關文章
相關標籤/搜索