Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

Change button color when disabled

$
0
0
Hi,

I use the following button and when isDisabled is true the button is transparent
(here its always true for the example but in my program its bound to command...)
what I want is that when the button is disabled the color remain the same just ligther,
how can I achive that?




   <Grid>

        <Button  
                                 Width="100"
                                 Height="25"
                                 Background="#f0ab00"
                                 Content="Run"
                                 FontSize="16"
                                 Foreground="#ffffff"
                                 IsDefault="True"
                                 Margin="10,0,20,0"
                                 IsEnabled="false" />

    </Grid>

Viewing all articles
Browse latest Browse all 18858

Trending Articles