Hello,
Is anyone know how to remove the border around the cell when we set the dataGrid.IsEnable to false?
I also attached the picture to more describe what I mean :).
Thanks
Vera
Hello Vera,
To remove these borders, you would have to create a style for the Editor. For example:
<Style TargetType="{x:Type igEditors:ValueEditor}">
<Style.Triggers>
<Trigger Property="IsEnabled" Value="False">
<Setter Property="BorderThickness" Value="0"/>
</Trigger>
</Style.Triggers>
</Style>
I can see on the screenshotthat you are using a theme, so make sure you have put that style in the XamDataGrid Resources section. If the style is not there it would not be picked up, because of the Theme.
Hope this helps,Alex.
Hello, Alex.
I forgot to say thanks to you. From your code, I try to dig it more deeper. I didn't know why, but the ValueEditor seems didn't work in my code. Because of that, I using this code to remove the border.
<Style TargetType="{x:Type igEditors:XamTextEditor}">
<Setter Property="Background" Value="Transparent"/>
And for others , I created another style and using XamNumericEditor for numeric value and XamDateTimeEditor for datetime value.
Thanks, your post help me much.