This question is locked. New answers and comments are not allowed.
Hello,
The ItemContainerStyleSelector on the RadListBox is not working.
Here is what I did:
The
BTW, if I set directly the NoEmailSpeakerItemContainerStyle with the ItemContainerStyle, it works fine!
Regards,
Adrien.
The ItemContainerStyleSelector on the RadListBox is not working.
Here is what I did:
public class SpeakerStyleSelector : StyleSelector { public Style NoEmailSpeakerStyle { get; set; } public override Style SelectStyle(object item, DependencyObject container) { if (item is Speaker) return this.NoEmailSpeakerStyle; return null; } }}<Style x:Key="NoEmailSpeakerItemContainerStyle" TargetType="telerik:RadListBoxItem"> <Setter Property="Foreground" Value="Red"/></Style> <local:SpeakerStyleSelector x:Key="SpeakerItemContainerStyleSelector" NoEmailSpeakerStyle="{StaticResource NoEmailSpeakerItemContainerStyle}"/>...<telerik:RadListBox ItemsSource="{Binding Speakers}" ItemContainerStyleSelector="{StaticResource SpeakerItemContainerStyleSelector}" />The
SelectStyle method is never called.BTW, if I set directly the NoEmailSpeakerItemContainerStyle with the ItemContainerStyle, it works fine!
Regards,
Adrien.