We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Re-sizing GridDataBoundGrids

Is there a parameter (eg. SizingGrip) that allows GridDataBoundGrids to be re-sized?

4 Replies

AD Administrator Syncfusion Team February 4, 2003 09:06 PM UTC

There is no GridDataBoundGrid specific property to handle sizing. But you can use the Control inherited Anchor to allow the grid to resize as you resize the parent form.


BK Bill Korchinski February 4, 2003 09:53 PM UTC

Can you point me to a code fragment that illustrates how to do this? Thanks.


AD Administrator Syncfusion Team February 5, 2003 06:30 AM UTC

Most of the time you do this in the designer. Just click on the grid, and then set the Anchor property in the property grid by clicking on the little diagram that appears. If you anchor the grid to all four sides, it will keep fixed distances from the sides as you size the form. Form code, you would do something like: this.gridControl1.Anchor = AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right; If your form has other controls on it, and you anchor the grid on all four side, any controls below or to the right should be re-anchored to the bottom-right. The default setting anchors all controls to the top-left of a form. Or, if your grid occupies the whole form, you can just set its DockStyle property to Fill, and it will always fill the form's client area as you size the form.


BK Bill Korchinski February 5, 2003 04:59 PM UTC

Thanks.

Loader.
Live Chat Icon For mobile
Up arrow icon