[]
Represents a collection of all ITableColumn objects in a specified ITable.
Each ITableColumn in the collection represents a column in the table. Use this interface to access table columns by index or name, and to work with the complete set of columns in a table.
public interface ITableColumns
Public Interface ITableColumns
worksheet.Range["A1:B3"].Value = new object[,] {
{"Name", "Value"},
{"A", 100},
{"B", 200}
};
ITable table = worksheet.Tables.Add(worksheet.Range["A1:B3"], true);
ITableColumns columns = table.Columns;
ITableColumn column = columns[0];
| Name | Description |
|---|---|
| Count | Gets the number of ITableColumn objects in the collection. Use this property to determine how many columns are currently defined in a table. |
| this[int] | Gets the ITableColumn object at the specified zero-based index. Use this indexer to retrieve a column from the ITableColumns collection by its current position in the parent ITable. |
| this[string] | Gets the ITableColumn object that corresponds to the specified column name. |
| Name | Description |
|---|---|
| Add(int) | Adds a new column to the table and returns the created ITableColumn. If |
| Add(int, int) | Adds one or more columns to the table at the specified relative position. The position is zero-based. Existing columns at the specified position are shifted outward to make room for the new columns. |
| Delete(int, int) | Deletes one or more columns from the table.
The |