DataGridView - first cell appears blank when navigating bindingsource
20 pts.
0
Q:
DataGridView - first cell appears blank when navigating bindingsource
Hi,

In VB.NET I have a DataGridView bound to a BindingSource. If BindingSource's position is changed, the first cell (0,0) in the grid appears blank. If I click in this first cell, the underlying value appears and it can get edited. The value in first cell also re-appears when I click in another cell but this time it's the new clicked cell that is not showing it's value.

And leaving the DataGridView's focus doesn't make the values to show.

I have tried EndEdit on the BindingSource and the dgv but it changes nothing.

How can I get the DataGridView to always show all values ?


Thanks



Software/Hardware used:
.NET framework 3.5
ASKED: Nov 2 2009  4:03 PM GMT
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
0
10345 pts.
0
A:
 RATE THIS ANSWER
0
Click to Vote:
  •   0
  •  0
  • AddThis Social Bookmark Button
I found my mistake. In order to make the selection invisible, I had changed the SelectionBackColor to white so the text color was white on a white background. Setting the SelectionForeColor to black did the job. Selection highlight is invisible but values are now readable.
Last Answered: Nov 2 2009  9:01 PM GMT by ITKE   10345 pts.
0
0
Discuss This Answer:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _



_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

Docw   20 pts.  |   Nov 2 2009  8:28PM GMT

Hi,

You can forget my question. I found my mistake. In order to make the selection invisible, I had changed the SelectionBackColor to white so the text color was white on a white background. Setting the SelectionForeColor to black did the job. Selection highlight is invisible but values are now readable.

 

Carlosdl   29795 pts.  |   Nov 2 2009  10:39PM GMT

Thanks for posting back.

 
0