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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

creating a button to reset grid sizes

Thread ID:





51648 Nov 10,2006 05:01 AM UTC Nov 13,2006 04:56 AM UTC WinForms 3
Tags: GridControl
Charlie Mao
Asked On November 10, 2006 05:01 AM UTC


I was wondering if someone has a code snippet that allows you to reset the column and row size back to default after the user clicks and make changes to the size. TO be more clear, lets say the user resizes some columns and rows and decides to reset the changes, they can just click on a button. I am using a databoundgrid. Thanks.


Administrator [Syncfusion]
Replied On November 10, 2006 06:28 AM UTC

Hi Charlie,

Use the ResetSize method to reset the column/row size to defaultsize. Below is a code snippet

//Reset the Column index..

//Reset the Row index..

//After calling the ResetSize method, you should call the Refresh or Invalidate to repaint the grid.

Best Regards,

Charlie Mao
Replied On November 10, 2006 07:54 PM UTC

this is for a grid control right? is there a way to do it with a databound grid. Also maybe an example project would be helpful, if its not too much to ask. thank you so much.


Administrator [Syncfusion]
Replied On November 13, 2006 04:56 AM UTC

Hi Charlie,

Yes. The above code snippet is for GridControl. You can access the ResetSize method from the Model.RowHeights class. Please refer to the attached sample which implements the ResetSize method and let me know if you trying something different.

Sample : http://www.syncfusion.com/Support/user/uploads/ResetSize_3dfc130b.zip

Best Regards,


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon