| | |
DataGridView property not working as expected
Please support our C# advertiser: Intel Parallel Studio Home
Thread Solved |
Start a new Forms application.
Add a DataGridView control to the Form.
Add a few Columns to the DataGridView.
In the properties window select the ColumnHeadersDefaultCellStyle (ahh what's in a name...) property.
A dialog opens. Change the appearance BackColor to whatever color you like.
Run the application. On my system I never get the chosen color for the column headers.
Anyone any ideas?
Add a DataGridView control to the Form.
Add a few Columns to the DataGridView.
In the properties window select the ColumnHeadersDefaultCellStyle (ahh what's in a name...) property.
A dialog opens. Change the appearance BackColor to whatever color you like.
Run the application. On my system I never get the chosen color for the column headers.
Anyone any ideas?
Today is a gift, that's why it is called "The Present".
Make love, no war. Cave ab homine unius libri.
Danny
Make love, no war. Cave ab homine unius libri.
Danny
Strange
It works with me...
It works with me... BI Developer | LINKdotNET
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
Check for this (msdn):
I've tried to set the EnableHeadersVisualStyles to false and it's working.
•
•
•
•
If visual styles are enabled and EnableHeadersVisualStyles is set to true, all header cells except the TopLeftHeaderCell are painted using the current theme and the ColumnHeadersDefaultCellStyle values are ignored.
So what if you can see the darkest side of me?
No one would ever change this animal I have become
Help me believe it's not the real me
Somebody help me tame this animal
No one would ever change this animal I have become
Help me believe it's not the real me
Somebody help me tame this animal
•
•
•
•
I've tried to set the EnableHeadersVisualStyles to false and it's working.
+ EnableHeadersVisualStyles = true and it's also working...
BI Developer | LINKdotNET
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
![]() |
Other Threads in the C# Forum
- Previous Thread: c#problem
- Next Thread: Keypress not working
| Thread Tools | Search this Thread |
.net access algorithm angle array barchart bitmap box broadcast c# capturing check checkbox client combobox control conversion convert csharp custom database datagrid datagridview dataset datetime dbconnection degrees delegate design development disappear draganddrop drawing encryption enum event excel file firefox form format forms function gdi+ httpwebrequest image index input install java label leak libraries list listbox mandelbrot math monodevelop mouseclick msword mysql operator path pause photoshop picturebox pixelinversion post programming radians regex remote remoting richtextbox round server sleep socket sql statistics stream string table tcpclientchannel text textbox thread time timer update usercontrol validation virtualization visualbasic visualstudio webbrowser windows winforms wpf xml






