Increase Datagridview size by dragging the form

I

Irfan

Hi,

I have a datagridview and some Buttons on a form. When I drag the form down
to increase its size at run time, i want the datagridview also to increase
in size so that i can view all the data in the grid at a time, instead of
scrolling.
This is a common scenario but i am not able to figure out how to do this.

TIA
Irfan
 
R

RobinS

I don't know where the buttons on your form are. If they are
at the top, Set the anchor properties of your DataGridView
to Left, Right, Bottom. If your buttons are elsewhere, just act
accordingly.

You can also add a panel to your form and put the DGV inside it
(dock inside parent). Then set the anchoring properties on the panel.

Robin S.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top