RadColorPaletteView throws NullReferenceException during key press

2 posts, 0 answers
  1. Tony
    Tony avatar
    2 posts
    Member since:
    May 2011

    Posted 10 May 2011 Link to this post

    I am using a RadColorPaletteView with custom colours with 4 RadColorPaletteViewItem's in it each for a color:

    <telerik:RadColorPaletteView Grid.Column="0" x:Name="customPaletteView" 
                             Grid.Row="0" AllowDrop="False">
                <telerik:RadColorPaletteViewItem Color="Green" IsEnabled="True" />
                <telerik:RadColorPaletteViewItem Color="Black" Content="Black" IsEnabled="False" />
                <telerik:RadColorPaletteViewItem Color="Red" Content="Red" IsEnabled="True" />
                <telerik:RadColorPaletteViewItem Color="Yellow" Content="Yellow" IsEnabled="True" />            
    </telerik:RadColorPaletteView>
    And the code behind:
    private void UserControl_Loaded(object sender, RoutedEventArgs e)
    {            
        customPaletteView.SelectedIndex = -1;
        customPaletteView.Focus();       
    }

    I am clearing the selected index and setting the focus to the color palette view control. Now if I click somewhere inside the color palette view control without selecting any color(RadColorPaletteViewItem) and press any keyboard key then a NullReferenceException is raised.

    If I select a color and press a key then a CastException is thrown.
  2. Kiril Stanoev
    Admin
    Kiril Stanoev avatar
    1512 posts

    Posted 12 May 2011 Link to this post

    Hello Tony,

    Thank you very much for reporting this issue. I managed to reproduce it. I've added it in our PITS under the name "ColorPicker: RadColorPaletteView throws NullReferenceException after key press" and it will be available for tracking tomorrow the latest. We will do our best to fix the issue with any of the following internal builds. I've also updated your Telerik points accordingly.

    Kind regards,
    Kiril Stanoev
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top