You must Sign In to post a response.
  • Category: WPF

    Reg : Add two checkbox in datagridview in wpf

    Dear Member ,

    I am the new in WPF . can u tell the how to add two checkbox in the single cell .
  • #768532
    Hi,

    If you click on XAML page. You can able to see the line of codes with tag format.
    Suppose if you have created a Checkbox inside the cell then is will be displayed like,


    <Window x:Class="Anyname"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:Anyname"
    Height="300" Width="300">

    <Window.Resources>

    <DataTemplate x:Key="checkBoxTemplate">
    <CheckBox IsChecked="{Binding Path=Value}" IsThreeState="False"></CheckBox>
    </DataTemplate>

    </Window.Resources>




    So that Datatemplate is your text box where you have been created in the front end. Just copy the datatemplate and paste in the next line you will get the second checkbox in the same cell.

    Thanks,
    Mani


  • Sign In to post your comments