This project has moved. For the latest updates, please go here.

ColorPicker Hide Button

Aug 6, 2012 at 6:08 PM

Hi, I want to hide the ColorPicker button.
I've created a style for the button but I'm getting an error.

 

Here is the style:
<Style x:Key="ColorPicker" TargetType="{x:Type Button}">
    <Setter Property="Visibility" Value="Collapsed" />
</Style>

 

And here is the error message:
Set property 'Xceed.Wpf.Toolkit.ColorPicker.ButtonStyle' threw an exception.' Line number '85' and line position '157'.

 

What could I be doing wrong?

Thanks!

Developer
Aug 7, 2012 at 2:15 PM

The reason of the error is because if this stye is applied to a ColorPicker.Style, the targetType is not a ColorPicker.

What button do you want to hide ? The one opening the colorPicker or the one named "Advanced" opening the ColorCanvas ?

Aug 7, 2012 at 7:50 PM

The one openning the ColorPicker so it would look like the one in the figure:

http://www.telerik.com/ClientsFiles/379681_ColorPicker.PNG

 

 

Hugo.

Developer
Aug 8, 2012 at 2:31 PM

Thank you, an issue has been created. This feature will be added on the next version.

Aug 20, 2012 at 6:05 PM

This following issue as been created based on this discussion:

http://wpftoolkit.codeplex.com/workitem/18504