Back to Devexpress

Column.AutoFit() Method

officefileapi-devexpress-dot-spreadsheet-dot-column-f210ed28.md

latest2.2 KB
Original Source

Column.AutoFit() Method

Adjusts the column width to accommodate cell content.

Namespace : DevExpress.Spreadsheet

Assembly : DevExpress.Spreadsheet.v25.2.Core.dll

NuGet Package : DevExpress.Spreadsheet.Core

Declaration

csharp
void AutoFit()
vb
Sub AutoFit

Remarks

To automatically fit the width of several columns to the content, use the ColumnCollection.AutoFit method.

To set the column width value in required units of measurement, use the Column.Width, Column.WidthInCharacters or Column.WidthInPixels property (see the How to: Specify Row Height or Column Width example).

See Also

Width

WidthInCharacters

WidthInPixels

DefaultColumnWidth

How to: Specify Row Height or Column Width

Rows and Columns in Spreadsheet Documents

Column Interface

Column Members

DevExpress.Spreadsheet Namespace