Click here to Skip to main content
15,888,330 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
Hi, I have created a DataGrid in C# windows form application. Data in datgrid loading ok. But its only visible when rows or cell are selected. I did not change anything from default.

Its not giving any errors.

So How can I get the datagrid to show data without selection?

What I have tried:

I checked the DefaultCellStyle Property, Back color and forecolor are different.
Posted
Updated 12-Oct-16 9:55am
Comments
[no name] 10-Oct-16 14:38pm    
Did you try Refresh()ing your grid?
Suvendu Shekhar Giri 10-Oct-16 14:40pm    
What are the colors set for DefaultCellStyle BackColor & ForeColor?
Also have a look at RowStyle property.
Member 12229842 12-Oct-16 15:54pm    
Yeah, It worked. I changed the forecolor and back color of rowstyle property.
Karthik_Mahalingam 11-Oct-16 4:14am    
datagridview?
post a screenshot of it
Shambhoo kumar 11-Oct-16 4:25am    
Kindly check your dataGridView Formating property.

1 solution

I changed the backcolor and forecolor of Rowstyle property and it worked.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900