if(checkBox1.IsChecked.Value)
{
btnSumbit.IsEnabled = true;
}
else
{
btnSumbit.IsEnabled = false;
}
IsEnabled="{Binding ElementName=checkBox1, Path=IsChecked}"
<Button x:Name="btnSumbit" IsEnabled="{Binding ElementName=checkBox1, Path=IsChecked}" Content="Button" HorizontalAlignment="Left" Margin="49,121,0,0" VerticalAlignment="Top" Width="75"/>
<Window.Resources>
<local:IsEnabled x:Key="IsEnabledConverter"/>
</Window.Resources>
if((bool) values[0] && (bool) values[1])
{
return true;
}
return false;
}
if(checkBox1.IsChecked.Value)
{
btnSumbit.IsEnabled = true;
}
else
{
btnSumbit.IsEnabled = false;
}
IsEnabled="{Binding ElementName=checkBox1, Path=IsChecked}"
<Button x:Name="btnSumbit" IsEnabled="{Binding ElementName=checkBox1, Path=IsChecked}" Content="Button" HorizontalAlignment="Left" Margin="49,121,0,0" VerticalAlignment="Top" Width="75"/>
<Window.Resources>
<local:IsEnabled x:Key="IsEnabledConverter"/>
</Window.Resources>
if((bool) values[0] && (bool) values[1])
{
return true;
}
return false;
}
if(checkBox1.IsChecked.Value)
{
btnSumbit.IsEnabled = true;
}
else
{
btnSumbit.IsEnabled = false;
}
IsEnabled="{Binding ElementName=checkBox1, Path=IsChecked}"
<Button x:Name="btnSumbit" IsEnabled="{Binding ElementName=checkBox1, Path=IsChecked}" Content="Button" HorizontalAlignment="Left" Margin="49,121,0,0" VerticalAlignment="Top" Width="75"/>
<Window.Resources>
<local:IsEnabled x:Key="IsEnabledConverter"/>
</Window.Resources>
if((bool) values[0] && (bool) values[1])
{
return true;
}
return false;
}
btnSumbit.IsEnabled = checkBox1.IsChecked.Value;
Copyright © 2024, NextGenUpdate.
All Rights Reserved.