Home Forums WinForms controls Xceed Grid for WinForms getfittedwidth-method for unbound detailgrids Reply To: getfittedwidth-method for unbound detailgrids

User (Old forums)
Post count: 23064

Hello AndreC
thanks for your answer!

What is the right syntax to get the created detailgrid, not the template?
Here is my code to add the detailgrid to GridControl1:

detail = New Detailgrid
…(adding columns, stylesheets)…


…- after filling the cells with contents, at last this sub is called:
call GridColumnwidth(detail)

Private Sub GridColumnwidth(ByVal obj As DetailGrid)
Dim column As Column
For Each column In obj.Columns
column.Width = column.GetFittedWidth()
Next column
End Sub

Do you know what is wrong?


Imported from legacy forums. Posted by VUser (had 405 views)