Rad Color Picker - Selected Color click event

3 posts, 0 answers
  1. anwar
    anwar avatar
    23 posts
    Member since:
    Jun 2009

    Posted 02 Mar 2010 Link to this post


    I want to fire the click event for the selected color from the MainPalette/StandardPalette list of colors, the reason for firing the click event is the SelectedColorChanged event is not firing. Please see the below Process. 

    Can you help how to do this. 

    I am using RadColorPicker to format the RadGridview columns. Here is what i am trying to do. I have a toolbar with RadColorPicker to set the font color, Gridview with three columns.
    1. Select the column 1(radgridview doesnot support selecting the entire column, so i am using cellselected event to select the column) and click on the font color picker  from Toolbar and select the  color Red (SelectedColorChanged event fires and setting the gridview cell style to set the font color for the column1 ) .
    2. Select the Column 2, click on the font color picker and the seleced color is Red, when i click on the Red color, the SelectedColorChanged event is not firing(the reason i am not selecting different color).
    Note : I donot want to use the RadColorPicker_Click event, cause when i select the column 1 , my toolbar  fontcolor picker selected color has to show the Red, Column 3, the deault color shows to black for the font color picker. There is a two way communications between Tool Bar RadColorPicker and Gridview Columns.

  2. Bobi
    Bobi avatar
    513 posts

    Posted 04 Mar 2010 Link to this post

    Hello anwar,

    You can accomplish the desired functionality by using the following:
    this.colorPicker.DropDownOpened += new EventHandler(picker_DropDownOpened);
     void picker_DropDownOpened(object sender, EventArgs e)
       Popup popup = this.picker.ChildrenOfType<Popup>()[0];
       RadColorSelector selector = VisualTreeHelper.GetChild(popup.Child, 0) as RadColorSelector;
             selector.AddHandler(RadColorPaletteViewItem.MouseLeftButtonDownEvent, new System.Windows.Input.MouseButtonEventHandler(this.SelectorItemMouseClick), true);
    private void SelectorItemMouseClick(object sender, MouseButtonEventArgs e)
                    //add the desired functionality here

    Kind regards,
    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.
  3. DevCraft R3 2016 release webinar banner
  4. namratha
    namratha avatar
    5 posts
    Member since:
    Nov 2010

    Posted 11 Nov 2010 Link to this post

    Popup missing assembly reference
Back to Top