Here:
sp.setOnItemSelectedListener(new SpinnerActivity());
You are trying to instantiate another activity and you try to set it as the listener. That won't work because Android Activities don't like it to get instantiated explicitly.
Try implementing listener for your spinner like this:
sp.setOnItemSelectedListener(new OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> arg0, View arg1,
int arg2, long arg3) {
// TODO Auto-generated method stub
}
@Override
public void onNothingSelected(AdapterView<?> arg0) {
// TODO Auto-generated method stub
}
});
the SpinnerActivity you should not need then anymore