Hi,
I have an issue while working in Vista OS.
When the Active cell is navigated using arrow keys, the cell become white, i.e., the content in cell is not visible. In Windows Xp there is no such issue seen.
I am attaching a project with this mail so that the issue can be understood clearly.
1. First click a cell using mouse (Now the row will be selected).
2. Press Tab key, now the next cell become active.
3. Press any arrow key.
Now the active cell will be empty.
Note:- I have implemented IUIElementDrawFilter interface to avoid the active row. If I am not implementing this interface then I have to set the active row appearance as white, but this makes problem when the row is both active and selected.
Please suggest me any solution for this.
Regards,
Ceaser
When you press the tab key, the cell you tab to becomes the ActiveCell. This is okay, because there is no ActiveCellAppearance applied to the grid, so the ForeColor of the cell does not change.
When you use the arrow key, the cell becomes both Active and Selected. The selected cell uses the system highlight color, which happens to be white. So you get white text on a white background - since your drawfilter it making the background white.
You will need to use a DrawFilter to change the ForeColor of the cell, as well as the BackColor.
HOWTO:How can I have Selected cells in a grid maintain their forecolor?