[android-developers] Simple code that works in 3.0 but not in 2.3.3 (with support lib)
Hi,
Regards,
-- Why does the simple code below work in Android 3.0, but not in 2.3.3 ???
In 2.3.3, it shows only a blank screen.
Any help would be appreciated. import android.os.Bundle;
import android.support.v4.app.ListFragment;
import android.widget.ArrayAdapter;
public class TestListFragment extends ListFragment {
private ArrayAdapter<String> myAdapter;
private String[] data = {"One", "Two", "Three"};
@Override
public void onActivityCreated(Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
myAdapter = new ArrayAdapter<String>(getActivity(), android.R.layout.simple_list_item_1, data);
setListAdapter(myAdapter);
}
}
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
---
You received this message because you are subscribed to the Google Groups "Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home