ExcelTablesCollectionAdd Method |
Creates an Excel table from a range of cells. The first row of the range is the header row: its cells
become the names of the table columns (empty header cells get the names Column1, Column2 ...). The table
gets the
Medium2 style, banded rows and filter buttons, like a new table in Excel.
Excel tables are available only in the Excel 2007+ (.xlsx) format.
Namespace: ExpertXls.ExcelLibAssembly: expertxls (in expertxls.dll) Version: 10.0.0
Syntaxpublic ExcelTable Add(
string name,
ExcelRange range
)
Public Function Add (
name As String,
range As ExcelRange
) As ExcelTable
Parameters
- name String
- The name of the table, used in formulas with structured references. It must start with
a letter or an underscore, cannot contain spaces and must be unique in the workbook.
- range ExcelRange
- The range of the table, including the header row. It cannot overlap another table.
Return Value
ExcelTableThe new table.
See Also