I am using 1.5. i'm not sure why it isnt working.
this is my code:
final CharSequence[] tags = {"first", "2nd", "third"};
                        boolean[] f=new boolean[tags.length];
                        final AlertDialog.Builder builder = new 
AlertDialog.Builder(this);
                        builder.setTitle("Filter");
                        builder.setMultiChoiceItems(tags, f, null);
                        builder.setPositiveButton(android.R.string.ok, new
                                        DialogInterface.OnClickListener() {
                                public void onClick(DialogInterface dialog, int
                                                whichButton) {
                                        
((AlertDialog)dialog).getListView().getCheckedItemPositions() ;
                                        Log.i("EasyChef", "filter checked ");
                                }
                        });
                        builder.create();
                        builder.show();

On Sep 27, 8:51 pm, Mark Murphy <[email protected]> wrote:
> Boozel wrote:
> > the complier underlines the getListView() section and gives the error
> > "the method getListView() is undefined for the type AlertDialog"
>
> http://d.android.com/reference/android/app/AlertDialog.html#getListView()
>
> That method has been around since Android 1.5. If you are targeting an
> earlier SDK version, that might explain the problem.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Looking for Android opportunities?http://wiki.andmob.org/hado
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to