[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.ITables

ITables Interface

Represents the collection of all ITable objects in a worksheet.

Each ITable object represents a table in the worksheet. Use this interface to access existing tables, add new tables, and enumerate the tables returned by Tables.

Namespace: GrapeCity.Documents.Excel
Assembly: DS.Documents.Excel.dll
Syntax
public interface ITables : IEnumerable
Public Interface ITables
    Inherits IEnumerable
Examples
worksheet.Range["A1:B3"].Value = new object[,] {
    {"Name", "Value"},
    {"Test", 100}
};
ITables tables = worksheet.Tables;
ITable table = tables.Add(worksheet.Range["A1:B3"], true);

Properties

Name Description
Count

Gets the number of ITable objects in this collection.

Use this property to get the number of tables defined on the worksheet.

this[int]

Gets the ITable object at the specified index.

Use this indexer to retrieve an existing table from the collection returned by Tables.

this[string]

Gets the ITable object with the specified name.

Use this indexer to retrieve an existing table from the collection returned by Tables.

Methods

Name Description
Add(IRange, bool)

Creates a table that includes the specified range of cells.

Use this method to convert a worksheet range into a table. Set containsHeader to true when the first row in the range should be used as the table header row.

FromJson(string)

Loads the table collection from the specified JSON string.

ToJson()

Generates a JSON string from the tables in the worksheet.