Click here to Skip to main content
15,881,248 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hello guys,
I have datagridview in my form which has SQL columns inside, to those columns I set width with this code:
dataGridView1.Columns["name"].Width = 353;

Problém is that those columns doesnt automatically resize width when I maximize size of form when i run this program(also datagridview automatically resizes and fills the whole form because i set ANCHOR to it, but columns has the same width as before).

Is there any way to set to those columns min width and auto resize them depending to the size of form?

Thanks in advance
Posted
Updated 5-Jul-13 10:19am
v2
Comments
Zoltán Zörgő 5-Jul-13 16:18pm    
Just a note: a form has no resolution, just a size.
mareksip 5-Jul-13 16:19pm    
thanks, my bad :)

1 solution

I solved this usisng MinimumWidth.
 
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