

'DeclarationPublic Class Column Inherits LinearWorksheetElement
'UsageDim instance As Column
public class Column : LinearWorksheetElement
using( var doc = Workbook.Load( "test.xlsx") ) { var worksheet = doc.Worksheets[ 0 ]; worksheet.Columns[ 1 ].Cells[ 1 ].Value = new DateTime( 2021, 7, 1, 10, 22, 33 ); // Sets “B2”. worksheet.Columns[ 2 ].Width = 65d; doc.Save(); }
System.Object
Xceed.Workbooks.NET.WorkbookElement
Xceed.Workbooks.NET.WorksheetElement
Xceed.Workbooks.NET.StyledWorksheetElement
Xceed.Workbooks.NET.LinearWorksheetElement
Xceed.Workbooks.NET.Column
| Name | Description | |
|---|---|---|
![]() | BestFit | Gets or sets if the Column's Width will be adjusted to fit the Cells' largest content. |
![]() | Cells | Gets the ColumnCellCollection. |
![]() | DataValidation | Sets the Column's DataValidation. |
![]() | Id | Gets the Id of a specific column in a worksheet. The first column starts at Id 0 and last column is located at Id 16383. (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
![]() | IdName | Gets the index of the Column and returns it as a letter. |
![]() | IsHidden | Gets or sets if the Row or Column is hidden or not. (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
![]() | Style | Gets the Style used by the Worksheet element. (Inherited from Xceed.Workbooks.NET.StyledWorksheetElement) |
![]() | Width | Gets or sets the Column's width. |
| Name | Description | |
|---|---|---|
![]() | AddConditionalFormatting | Adds ConditionalFormatting to the Column. |
![]() | AutoFit | Overridden. Adjusts the Column's Width based on the Cell with the widest content. |
![]() | Clear | Removes specific elements from the LinearWorksheetElement. (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
![]() | ClearConditionalFormattings | Removes all ConditionalFormattings from the Column. |
![]() | GetConditionalFormattings | Gets the Column's ConditionalFormattings. |
![]() | RemoveConditionalFormatting | Removes a specific ConditionalFormatting from the Column. |
![]() | ReplaceContent | Searches into the content of the Column and replaces all occurences of a specific value with a new value. (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
![]() | ReplaceContents<TSearch,TNew> | Searches into the content of the LinearWorksheetElement and replaces all instances of the searchValues with their corresponding newValues. (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
| Name | Description | |
|---|---|---|
![]() | AddCell | Overridden. |
![]() | CanWrite | Overridden. |
![]() | GetCells | Overridden. |
![]() | GetNewStyle | (Inherited from Xceed.Workbooks.NET.StyledWorksheetElement) |
![]() | Read | Overridden. |
![]() | ReadStyle | Overridden. |
![]() | RemoveCell | Overridden. |
![]() | Reset | Overridden. |
![]() | UpdateChildrenStyleProperty | (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
![]() | UpdateStyleBorders | Overridden. |
![]() | Write | (Inherited from Xceed.Workbooks.NET.LinearWorksheetElement) |
![]() | WriteStyle | Overridden. |
.NET: net5.0, net5.0-windows, net6.0, net6.0-macos, net6.0-windows, net7.0, net7.0-macos, net7.0-windows, net8.0, net8.0-browser, net8.0-macos, net8.0-windows, net9.0, net9.0-browser, net9.0-macos, net9.0-windows, net10.0, net10.0-browser, net10.0-macos, net10.0-windows.
.NET Framework: net40, net403, net45, net451, net452, net46, net461, net462, net463, net47, net471, net472, net48, net481.