Skip to content

Commit b5d4968

Browse files
ES-976509 - Resolved the ReadMe file changes
1 parent 87c9786 commit b5d4968

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

DataGridWithMouseHover.png

17.5 KB
Loading

README.md

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
1-
# How to apply the row mouse hover effect in DataGrid(SfDataGrid)?
1+
# How to Apply the Row Mouse Hover Effect in WinForms DataGrid?
22

3-
## About the sample
4-
This example illustrates how to apply the row mouse hover effect in DataGrid(SfDataGrid)?
3+
This example illustrates how to apply the row mouse hover effect in [WinForms DataGrid](https://www.syncfusion.com/winforms-ui-controls/datagrid) (SfDataGrid)?
54

6-
SfDataGrid allows you to change the color of the hovered row using the TableControl.MouseMove and QueryCellStyle events.
5+
By default, `DataGrid` does not provide the direct support for change the background color when mouse hover. You can change the background color by using [SfDataGrid.QueryCellStyle](https://help.syncfusion.com/cr/windowsforms/Syncfusion.WinForms.DataGrid.SfDataGrid.html#Syncfusion_WinForms_DataGrid_SfDataGrid_QueryCellStyle) event.
76

8-
```C#
7+
``` csharp
98
sfDataGrid1.TableControl.MouseMove += TableControl_MouseMove;
109
sfDataGrid1.QueryCellStyle += sfDataGrid1_QueryCellStyle;
1110
sfDataGrid1.TableControl.MouseLeave += TableControl_MouseLeave;
@@ -40,8 +39,6 @@ void TableControl_MouseMove(object sender, MouseEventArgs e)
4039
sfDataGrid1.TableControl.Invalidate(sfDataGrid1.TableControl.GetRowRectangle(hoveredRowIndex, true));
4140
}
4241
}
43-
4442
```
4543

46-
## Requirements to run the demo
47-
Visual Studio 2015 and above versions
44+
![DataGrid applied with mouse hover effect](DataGridWithMouseHover.png)

0 commit comments

Comments
 (0)