This is a migrated thread and some comments may be shown as answers.

BestFit problem on Q3 2009

1 Answer 51 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Mathieu Roy
Top achievements
Rank 1
Mathieu Roy asked on 08 Jan 2010, 02:41 PM

Hi,

We have a problem with the rendering of the grid(version 2009.3.9.1203) since we upgrade to version 2009 Q3.

He is the code we use to set the columns width :

 

 

Me.Instance.DataSource = Value

 

 

Me.Instance.GridElement.BeginUpdate()

 

 

 If Me.Instance.MasterGridViewTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.None Then

 

 

 

   For Each column As GridViewDataColumn In Me.Instance.Columns

 

      column.BestFit()

 

   Next

 

 

 

End If
Me.Instance.GridElement.EndUpdate()

Since we update, the column.BestFit() don't work and all column have like width of 1...? We usually have grid with more than 10 columns and it has always work fine.

What should we do to fix it?

thx

 

1 Answer, 1 is accepted

Sort by
0
Martin Vasilev
Telerik team
answered on 13 Jan 2010, 03:33 PM
Hello Mathieu Roy,

Thank you for writing. I have managed to reproduce the described issue with the latest release - Q3 2009 SP1. We will investigate this further. However - to avoid this - you can use either BestFitColumns method, or remove Begin/EndUpdate methods:

this.radGridView1.MasterGridViewTemplate.BestFitColumns();

I have updated your Telerik points for bringing our attention to this. Do not hesitate to contact us again if you need help.

Best wishes,
Martin Vasilev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
GridView
Asked by
Mathieu Roy
Top achievements
Rank 1
Answers by
Martin Vasilev
Telerik team
Share this question
or