基本上我收到此錯誤:片段InstantiationException
android.support.v4.app.Fragment$InstantiationException: Unable to instantiate fragment Archenemy: make sure class name exists, is public, and has an empty constructor that is public
現在我知道已經有很多,其中的問題是他們沒有一個空的構造問題。我會的,你會看到的。我的問題是,還有什麼可能導致此錯誤?
public class Archenemy_Activity extends android.support.v4.app.Fragment {
public Archenemy_Activity() {
}
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
return inflater.inflate(R.layout.archenemy_layout, container, false);
}
}
謝謝!
你有沒有在其他logcat中excpetions –