After installing 12.1, I've noticed that code that was auto sizing all the grid columns using the PerformAutoResizeColumns method now seems to be resizing based only on the column headers. I've created a simple test program in 11.2 and 12.1 and the results are different. I've tried setting the AutoResizeColumnWidthOptions to All, but it doesn't seem to have any effect. I've attached a zip file that contains both versions of the project.
Hi,
I will be happy to assist you with this issue.
I have tested your sample and was able to reproduce the issue mentioned in your post. I have created case number CAS-96759-C77CD2 for you to better assist you with this issue going forward. To access the case, simply log into your Infragistics Account and click on SupportActivity.
Please let me know if you have additional questions regarding this matter.
Our developers have completed their review of development ID 117972. They have determined that this is not a bug for the following reasons:
This worked previously because the grid was initializing certain metrics before the first time the grid painted. This was wrong and caused other problems.
The new behavior that you are getting here is correct. The PerformAutoResizeColumns is sizing based on the VisibleRows in the grid, and since the gird has never painted, there are no visible rows at this point.
You can easily work around this by specifying a number or row or by specifying AllRowsInGrid instead of VisibleRows. Or, you can call Update on the grid right before calling PerformAutoResizeColumns which would force the grid to paint.
If you have more information regarding this issue that may require a reevaluation, or require further explanation, please let me know.