How to resize form to fit DataGridView?

Posted by slave016 on Stack Overflow See other posts from Stack Overflow or by slave016
Published on 2010-03-28T20:34:09Z Indexed on 2010/03/28 20:43 UTC
Read the original article Hit count: 232

Filed under:
|
|
|

I have a form that contains dataGridView, whose coloumn are set to

dgrv1.Width =dgrv1.Columns.GetColumnsWidth(DataGridViewElementStates.Visible)+20;

I want to make the form to automaticaly follow the with of dataGridView...

Also, on maximized, I would like it to grow in height only.

Any sugestions?

© Stack Overflow or respective owner

Related posts about resize

Related posts about form