This question is locked. New answers and comments are not allowed.
Hi,
since the CheckedItems collection is no DependencyProperty of the DataBoundListBox, I can not use something like
in XAML code. Is there an easy way to achieve this behaviour?
Thank you in advance
Robert
since the CheckedItems collection is no DependencyProperty of the DataBoundListBox, I can not use something like
<RadDataBoundListBox ItemsSource="{Binding List}" CheckedItems="{Binding FilteredList, Mode=TwoWay}" ...
Thank you in advance
Robert
10 Answers, 1 is accepted
0
Hi Robert,
Currently we do not support bound mode for the CheckedItems collection in RadDataBoundListBox/RadJumpList. Since we have had a couple of requests to implement this feature, we will consider it for our next major release but currently our plans for Q1 2012 are already tight in schedule and we will not be able to include this feature in the upcoming package.
Greetings,
Deyan
the Telerik team
Currently we do not support bound mode for the CheckedItems collection in RadDataBoundListBox/RadJumpList. Since we have had a couple of requests to implement this feature, we will consider it for our next major release but currently our plans for Q1 2012 are already tight in schedule and we will not be able to include this feature in the upcoming package.
Greetings,
Deyan
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
0
Ilija
Top achievements
Rank 1
answered on 28 Jan 2012, 07:27 AM
Hi Robert,
a simple workaround for this problem is, to implement the ItemCheckedStateChange Event in your xaml code behind file and to fill a ObservableCollection<T> and set object for the type parameter. Then when you check or uncheck your add/remove the currently checked item to this collection. You then simply bind to this collection:
This is against the MVVM rules, but it is a workaround that can be used, until the Telerik implementation is working. Afterwards you can get your bound data like this (maybe there is a shorter way to get the values):
a simple workaround for this problem is, to implement the ItemCheckedStateChange Event in your xaml code behind file and to fill a ObservableCollection<T> and set object for the type parameter. Then when you check or uncheck your add/remove the currently checked item to this collection. You then simply bind to this collection:
private
void
lstBrowser_ItemCheckedStateChanged(
object
sender, Telerik.Windows.Controls.ItemCheckedStateChangedEventArgs e)
{
if
(e.IsChecked)
{
App.ViewModelForApp.CheckedItems.Add(e.Item);
}
else
{
App.ViewModelForApp.CheckedItems.Remove(e.Item);
}
}
This is against the MVVM rules, but it is a workaround that can be used, until the Telerik implementation is working. Afterwards you can get your bound data like this (maybe there is a shorter way to get the values):
foreach
(var item
in
this
.CheckedItems)
{
itemsFileInformation.Enqueue(
((Telerik.Windows.Data.IDataSourceItem)item).Value
as
SkyDriveFileInformation);
}
0
Andrew
Top achievements
Rank 1
answered on 18 Jun 2013, 03:26 PM
has there been any updates to the controls since this thread ended? If not, I'll give this workaround a shot. thanks all
0
Hi Andrew,
You can use the workaround mentioned in this thread.
Let us know should you have additional questions.
Regards,
Deyan
Telerik
You can use the workaround mentioned in this thread.
Let us know should you have additional questions.
Regards,
Deyan
Telerik
Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
0
Matheus
Top achievements
Rank 2
answered on 04 Nov 2013, 06:10 PM
Did you guys managed to add the Dependency Property to the RadDataBoundListBox or should I use the workaround? Thanks a lot. It would be great to simply add the binding to keep my MVVM clean.
0
Hello Matheus,
This feature is still not implemented. We will escalate its priority in our TODO list though and will try to implement it for our next major release.
Regards,
Deyan
Telerik
This feature is still not implemented. We will escalate its priority in our TODO list though and will try to implement it for our next major release.
Regards,
Deyan
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINDOWS PHONE 7.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Derik
Top achievements
Rank 1
answered on 06 Dec 2013, 02:07 PM
Sucks that things like this would not be designed w/ MVVM in mind from the onset. Really is a disappointment. Oh well I guess I will use the work around....
0
esskar
Top achievements
Rank 1
answered on 11 Feb 2014, 11:57 PM
Hello,
the workaround is fine but how do i uncheck the items from code?
Regards,
Sascha
the workaround is fine but how do i uncheck the items from code?
Regards,
Sascha
0
Hello Sascha,
To uncheck or check items in code you simply need to remove or add them from/to the CheckedItems collection. Or there is something specific to your scenario that prevents you from doing that?
Regards,
Deyan
Telerik
To uncheck or check items in code you simply need to remove or add them from/to the CheckedItems collection. Or there is something specific to your scenario that prevents you from doing that?
Regards,
Deyan
Telerik
If you want to get updates on new releases, tips and tricks and sneak peek previews directly from the developers working on the UI for Windows Phone, subscribe to the blog feed now.
0
esskar
Top achievements
Rank 1
answered on 20 Feb 2014, 10:12 AM
thanks. works!