corelibraries-devexpress-dot-dataaccess-dot-excel-dot-excelworksheetsettings.md
Gets or sets the name of the worksheet from which data is imported.
Namespace : DevExpress.DataAccess.Excel
Assembly : DevExpress.DataAccess.v25.2.dll
NuGet Package : DevExpress.DataAccess
public string WorksheetName { get; set; }
Public Property WorksheetName As String
| Type | Description |
|---|---|
| String |
A String value that specifies the name of the worksheet from which data is imported.
|
The following example shows how to select the A1:F20 range of cells located on the Sheet1 worksheet using the WorksheetName and ExcelWorksheetSettings.CellRange properties.
ExcelWorksheetSettings worksheetSettings = new ExcelWorksheetSettings();
worksheetSettings.WorksheetName = "Sheet1";
worksheetSettings.CellRange = "A1:F20";
Dim worksheetSettings As New ExcelWorksheetSettings()
worksheetSettings.WorksheetName = "Sheet1"
worksheetSettings.CellRange = "A1:F20"
The following code snippets (auto-collected from DevExpress Examples) contain references to the WorksheetName property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
ExcelWorksheetSettings excelWorksheetSettings = new ExcelWorksheetSettings();
excelWorksheetSettings.WorksheetName = "Sheet1";
data-access-library-create-data-sources-at-runtime/CS/ExcelDataSourceSnippets/Code.cs#L33
ExcelWorksheetSettings excelWorksheetSettings = new ExcelWorksheetSettings();
excelWorksheetSettings.WorksheetName = "Sheet_Categories";
Dim excelWorksheetSettings As ExcelWorksheetSettings = New ExcelWorksheetSettings()
excelWorksheetSettings.WorksheetName = "Sheet1"
Dim excelSourceOptions As ExcelSourceOptions = New ExcelSourceOptions()
reporting-winforms-bind-excel-runtime/VB/BindingReportToExcelWorkbook/Form1.vb#L25
Dim excelWorksheetSettings As ExcelWorksheetSettings = New ExcelWorksheetSettings()
excelWorksheetSettings.WorksheetName = "Sheet_Categories"
' Specify import settings.
winforms-dashboard-bind-pie-item-to-data-in-code/VB/Dashboard_CreatePies/Form1.vb#L25
Dim importSettings = New DevExpress.DataAccess.Excel.ExcelWorksheetSettings()
importSettings.WorksheetName = "Data"
importSettings.CellRange = "A1:L100"
data-access-library-create-data-sources-at-runtime/VB/ExcelDataSourceSnippets/Code.vb#L31
Dim excelWorksheetSettings As New ExcelWorksheetSettings()
excelWorksheetSettings.WorksheetName = "Sheet_Categories"
See Also