Unable to resolve target 'android-8'

1677
2
01-22-2013 02:56 PM
NadeemQazi
New Contributor III
I have android sdk intalled with latest api (android 4.2) m using eclipse indigo . I also have installed arcgis sdk for android and added it in eclipse.however when i created my first application named hellowordactvity, the application Created hellowordactvity.java having following code. but the application did not run giving error  Unable to resolve target 'android-8' . need suggestions

import android.app.Activity; (it shows import android cannot be solved)
import android.os.Bundle;


import com.esri.android.map.MapView;


public class hellowordactvity extends Activity {

MapView mMapView ;

/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);

mMapView = new MapView(this);

}

@Override
protected void onDestroy() {
super.onDestroy();
}
@Override
protected void onPause() {
super.onPause();
mMapView.pause();
}
@Override protected void onResume() {
super.onResume();
mMapView.unpause();
}

}
0 Kudos
2 Replies
MilesWacker
New Contributor
What is your minimum sdk target in the Manifest file?  i.e.
<uses-sdk android:minSdkVersion="14"/>
0 Kudos
DanO_Neill
Occasional Contributor III
New projects created with the ArcGIS New Project Wizard default to our minimum Android Build Target support level, which is currently SDK version 10 API level 2.3.3.  Your reference to SDK version 8 implies you have an older version of the SDK installed.  You can either add the platform to your Android SDK as described here.  Or you can change the projects Android Build Target with these steps:

1. Right click the project and select Properties.
2. Choose Android from the tree on the left and select the appropriate Android Build Target on the right. 

If you upgrade to v10.1.1 you will need to use Target Name Android 2.3.3.
0 Kudos