# Worksheets

## Content



Worksheets are the individual grids contained in an Excel file. They are represented by [XLSheet](/componentone/api/wpf/online-excel/dotnet-framework-api/C1.WPF.Excel.4.6.2/C1.WPF.Excel.XLSheet.html) objects accessible through the **Sheets** property in the [C1XLBook](/componentone/api/wpf/online-excel/dotnet-framework-api/C1.WPF.Excel.4.6.2/C1.WPF.Excel.C1XLBook.html) class. Each sheet has a name and contains a collection of rows and columns. Individual cells can be accessed using the **XLSheet** indexer, which takes row and column indices.

The [Rows](/componentone/api/wpf/online-excel/dotnet-framework-api/C1.WPF.Excel.4.6.2/C1.WPF.Excel.XLSheet.Rows.html) and [Columns](/componentone/api/wpf/online-excel/dotnet-framework-api/C1.WPF.Excel.4.6.2/C1.WPF.Excel.XLSheet.Columns.html) collections in the **XLSheet** object extend automatically when you use their indexers. For example, if you write the following code and the sheet has fewer than 1001 rows, new rows will be automatically added, and a valid row will be returned. The same applies to [XLColumn](/componentone/api/wpf/online-excel/dotnet-framework-api/C1.WPF.Excel.4.6.2/C1.WPF.Excel.XLColumn.html) and [XLCell](/componentone/api/wpf/online-excel/dotnet-framework-api/C1.WPF.Excel.4.6.2/C1.WPF.Excel.XLCell.html) indexers. This is different from the behavior of most collection indexers in .NET, but it makes it very easy to create and populate **XLSheet** objects.

```vbnet
Dim sheet As XLSheet = C1XLBook1.Sheets(0)
Dim row As XLRow = sheet.Rows(1000)
```

```csharp
XLSheet sheet = c1XLBook1.Sheets[0];
XLRow row = sheet.Rows[1000];
```