This is a migrated thread and some comments may be shown as answers.

Select multiple items

22 Answers 125 Views
ListPicker
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Fredrik
Top achievements
Rank 1
Fredrik asked on 05 Jan 2012, 10:33 AM
Hi !!

Is it possible to have the listpicker (like the listpicker in th sl toolkit) to have the user choose one or more items in
the listpicker.
The SL tookit have a property "SelectionMode=Multiple" and have a special eventhandler that are getting an IList with the selected items.

Is this possible with the RadListPicker ?

Regards

Fredrik

22 Answers, 1 is accepted

Sort by
0
Valentin.Stoychev
Telerik team
answered on 06 Jan 2012, 10:20 AM
Hello,

Do you mean to have the multiple select option in the Popup only with checkboxes, or something else?

Regards,
Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Fredrik
Top achievements
Rank 1
answered on 07 Jan 2012, 04:43 PM

Hello

I mean with checkboxes.

Regards

Fredrik

0
Accepted
Georgi
Telerik team
answered on 11 Jan 2012, 09:26 AM
Hi Fredrik,

Thank you for your feature request.

We have it in our product backlog and we will do our best to implement it either for Q1 2012 or for the service pack afterwards. We are also thinking of extending the Popup part of the control by adding a JumpList in it so that large data can be grouped and easily navigated.

I hope this information is useful. Do not hesitate to write us back with any feedback you may have - it is most appreciated.

Regards,
Georgi
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Tim
Top achievements
Rank 1
answered on 25 Apr 2012, 06:10 AM
Hi Georgi,

It's now the end of April. Is there a new status on multi-selection mode for the list picker control? I'm finding myself having to move to all Telerik controls and I'm incredibly disappointed that we don't have a multi-select option for the list picker. I'm not sure what I'd even do for a workaround.

Thanks
0
Kiril Stanoev
Telerik team
answered on 26 Apr 2012, 01:32 PM
Hi Tim,

Thank you for contacting us. We are about to start the implementation of the desired feature. Just to further clarify, is the expected behavior similar to the one where you pick the day:

Kind regards,
Kiril Stanoev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Fredrik
Top achievements
Rank 1
answered on 26 Apr 2012, 01:36 PM
Hi !!

In my case it looks right.
Is this going to work in just popup or inline also ?

Regards

Fredrik
0
Tim
Top achievements
Rank 1
answered on 26 Apr 2012, 01:44 PM
Hi Kiril,
The alarm implementation is exactly what I would expect to see. I am assuming you would always see the full screen view even if you have a single item.
Are you able to provde an ETA?
0
Valentin.Stoychev
Telerik team
answered on 30 Apr 2012, 11:54 AM
Hi all,

we target our Q2.2012 release for this feature. It maybe implemented as a separate control (we are still not sure).

We will do our best to have it for mid-June timeframe. The idea is this control to work only in Popup mode. If you have any suggestions, ideas or any thought related to this functionality - please let us know!

Regards, Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Martin
Top achievements
Rank 1
answered on 17 May 2012, 10:09 AM
+1 vote for this feature from me - I have been expecting it's already there, because it is in WP7 toolkit Nov 2011.
0
Valentin.Stoychev
Telerik team
answered on 18 May 2012, 08:34 PM
Hi,

I can confirm this is coming for Q2 release. If someone needs the binaries earlier - please open a support ticker and we will send you a preliminary version.

All the best, Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Martin
Top achievements
Rank 1
answered on 19 May 2012, 12:20 PM

Just a note, the multiselect listpicker should have the possibility to return empty selection like the recurrence picker in the built-in Alarm clock application. Thanks.

0
Valentin.Stoychev
Telerik team
answered on 22 May 2012, 05:38 PM
Hi Martin,

Yes - we will have this feature in mind.

Greetings, Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Mike
Top achievements
Rank 1
answered on 05 Jul 2012, 02:45 PM
This control has a bug where the ItemsSource[0] is always selected by the control automatically if it is not in the SelectedItems collection.
In the sample code for this control, change categoryItemsSource[0], [1] to categoryItemsSource[1], [2] and you will see the bug, Items [0], [1], [2] will be selected by the control.

0
Valentin.Stoychev
Telerik team
answered on 05 Jul 2012, 02:48 PM
Hello Mike,

 
As I mentioned in the other thread - we are not able to reproduce this issue, so it is still not confirmed. Please refer to the initial thread until we resolve it.

Kind regards,
Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Karsten
Top achievements
Rank 1
answered on 19 Jul 2012, 09:18 AM
Hi,

It seems like the multiple selection works, however a question of how to display multiple items.

You have the delegate function SummaryForSelectedItemsDelegate  and I can see how I can manipulate the (summary) text from your example, but how do I display that text in the control when returning from the Popup?

I must be doing something wrong, because I get no text at all. Like the text 'No selection' when no items have been selected, I would like to show the text 'Items selected' when one or more item is in fact selected.

Thank you.

Karsten
0
Valentin.Stoychev
Telerik team
answered on 20 Jul 2012, 06:56 AM
Hi,

The text is displayed automatically, you do not need to do anything.

Do you have any custom styles, or templates?

Greetings, Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Karsten
Top achievements
Rank 1
answered on 20 Jul 2012, 07:21 AM
Hi,

I do not have any custom styles or templates.

This is my XAML:
            <telerikInput:RadListPicker Header="user shelf" PopupHeader="user shelf" InlineModeThreshold="5"
                                        x:Name="lpUserShelf" SelectionMode="Multiple"
                                        SelectionChanged="lpUserShelf_SelectionChanged">
                <telerikInput:RadListPicker.ItemTemplate>
                      <DataTemplate>
                        <StackPanel Orientation="Horizontal">
                            <TextBlock Text="{Binding Name}" />
                        </StackPanel>
                    </DataTemplate>
                </telerikInput:RadListPicker.ItemTemplate>
                <telerikInput:RadListPicker.PopupItemTemplate>
                    <DataTemplate>
                        <StackPanel Orientation="Horizontal">
                            <TextBlock Text="{Binding Name}" />
                        </StackPanel>
                    </DataTemplate>
                </telerikInput:RadListPicker.PopupItemTemplate>
            </telerikInput:RadListPicker>

I see no text in the control when I return from the popup.

Karsten
0
Karsten
Top achievements
Rank 1
answered on 20 Jul 2012, 08:21 AM
Hi Again,

I was somewhat unprecise in my last reply.

If I use the SummaryForSelectedItemsDelegate  delegate I get no text.

If I do not use it, I get the text/value if I only select one item. If I select two or more, I get the class name(s) and not the value.

Karsten
0
Valentin.Stoychev
Telerik team
answered on 20 Jul 2012, 08:37 AM
Hi,

Can you please paste the code of the delegate?

Greetings, Valentin.Stoychev
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Karsten
Top achievements
Rank 1
answered on 20 Jul 2012, 08:47 AM
private void lpUserShelf_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
    this.lpUserShelf.SummaryForSelectedItemsDelegate = SummaryForSelectedItemsDelegate;
}         

private
 object SummaryForSelectedItemsDelegate(IList list)
{
    var summary = String.Empty;
   for (var i = 0; i < list.Count; i++)
   {
       var isLast = i == list.Count - 1;
       var item = (UserShelf)list[i];
       summary = String.Concat(summary, item.Name);
       summary += isLast ? string.Empty : ", ";
    }             
    if (summary == String.Empty)
   {                 
        summary = "No selection";
   }             
    return summary;         
}

As explained in my previous post, then if I do not use the delegate, I get a text if only one item is selected,
class name if two (ore more are selected) and nothing if the delegate is used if at least one is selected.
0
Todor
Telerik team
answered on 20 Jul 2012, 08:58 AM
Hello Karsten,

When you use the delegate the Summary that gets displayed has the same Template as the ItemTemplate of the RadListPicker, so what you should do is have a delegate that returns an object that has a Name property, because this is the property that your ItemTemplate is bound to. For example:
return new MyDataObject() { Name = summary };


Greetings,
Todor
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Karsten
Top achievements
Rank 1
answered on 20 Jul 2012, 09:02 AM
Thank you!

Quick and execellent support as always.

Karsten
Tags
ListPicker
Asked by
Fredrik
Top achievements
Rank 1
Answers by
Valentin.Stoychev
Telerik team
Fredrik
Top achievements
Rank 1
Georgi
Telerik team
Tim
Top achievements
Rank 1
Kiril Stanoev
Telerik team
Martin
Top achievements
Rank 1
Mike
Top achievements
Rank 1
Karsten
Top achievements
Rank 1
Todor
Telerik team
Share this question
or