Worksheet
Two-dimensional grid organizing cells into rows and columns with filtering, sorting, formulas, and styling. Use to manage worksheet content, properties, and layout within a workbook.
Definition
Namespace:Telerik.Windows.Documents.Spreadsheet.Model
Assembly:Telerik.Windows.Documents.Spreadsheet.dll
Syntax:
public class Worksheet : Sheet, INotifyPropertyChanged, ISheet, IDisposable
Inheritance: objectNotifyPropertyChangedBaseSheetWorksheet
Implements:
Inherited Members
Methods
Creates a new WorksheetViewState instance initialized with default display settings.
protected override ISheetViewState CreateViewState()
A new worksheet view state.
Overrides:
Disposes the specified disposing.
Searches for the first occurrence of text in the worksheet matching the specified criteria and returns its location.
public FindResult Find(FindOptions findOptions)
The find options.
Returns:The first matching result, or null if not found.
Searches for all occurrences of text in the worksheet matching the specified criteria and returns their locations.
public IEnumerable<FindResult> FindAll(FindOptions findOptions)
The find options.
Returns:All matching results in the worksheet.
Gets the used cell range for specific cell property definitions.
public CellRange GetUsedCellRange(IEnumerable<IPropertyDefinition> propertyDefinitions)
The cell property definitions from CellPropertyDefinitions
Returns:The used cell range for specific cell property definitions.
Gets the used cell range for a specific cell property definition.
public CellRange GetUsedCellRange(IPropertyDefinition propertyDefinition)
The cell property definition from CellPropertyDefinitions
Returns:The used cell range for specific cell property definitions.
Protects the worksheet.
public void Protect(string password, WorksheetProtectionOptions options)
The password.
optionsWorksheetProtectionOptionsThe protection options of the worksheet.
Executes replace action according to the specified replace options.
public bool Replace(ReplaceOptions replaceOptions)
The replace options.
Returns:The value indicating whether a value was found to replace.
Executes replace all action according to the specified replace options.
public int ReplaceAll(ReplaceOptions replaceOptions)
The replace options.
Returns:The number of replacements made.
Properties
Provides access to the cell collection for reading and modifying cell content, formulas, and formatting.
public Cells Cells { get; }
The cells of the worksheet.
Provides access to charts visualizing data from the worksheet or other sources.
public ChartCollection Charts { get; }
The charts.
Provides access to the column collection for managing column widths, visibility, and column-level formatting.
public Columns Columns { get; }
The columns of the worksheet.
Provides access to modern threaded comments attached to cells in the worksheet.
public CommentCollection Comments { get; }
The comments.
Controls the default column width applied to columns without explicit width settings.
public ColumnWidth DefaultColumnWidth { get; set; }
The default width of the column.
Controls the default row height applied to rows without explicit height settings.
public RowHeight DefaultRowHeight { get; set; }
The default height of the row.
Provides access to the auto-filter configuration for hiding rows based on column criteria.
public AutoFilter Filter { get; }
The filtering of the worksheet.
Provides access to row and column grouping settings for outlining and collapsing data sections.
public GroupingProperties GroupingProperties { get; }
The grouping properties.
Controls how row and column headers are rendered, enabling custom labeling schemes beyond default A-Z and 1-N.
public HeaderNameRenderingConverterBase HeaderNameRenderingConverter { get; set; }
The header name rendering converter.
Provides access to the collection of hyperlinks defined in the worksheet for navigation and external references.
public HyperlinkCollection Hyperlinks { get; }
The hyperlinks.
Provides access to floating images positioned on the worksheet.
public ImageCollection Images { get; }
The images.
Provides access to worksheet-scoped named ranges and constants that can be referenced in formulas.
public NameCollection Names { get; }
The collection of defined names of the worksheet.
Provides access to cell notes (legacy comments) attached to cells in the worksheet.
public NoteCollection Notes { get; }
The notes.
Controls which operations users can perform on a protected worksheet, such as inserting rows or formatting cells.
public WorksheetProtectionOptions ProtectionOptions { get; }
The protection options.
Provides access to the row collection for managing row heights, visibility, and row-level formatting.
public Rows Rows { get; }
The rows of the worksheet.
Returns the base page setup implementation for this sheet type.
protected override sealed SheetPageSetupBase SheetPageSetup { get; }
The sheet page setup.
Overrides:
Provides access to the current sort configuration applied to the worksheet data.
public SortState SortState { get; }
The sort state.
Returns the sheet type identifier, always SheetType.Worksheet for worksheet instances.
public override SheetType Type { get; }
The type of the sheet.
Overrides:
Returns the bounding range encompassing all cells with content or formatting, indicating the worksheet's active data area.
public CellRange UsedCellRange { get; }
The used cell range.
Provides access to display settings including zoom, frozen panes, selection, and gridline visibility.
public WorksheetViewState ViewState { get; }
The view state of the worksheet.
Provides access to page layout settings for printing and PDF export, including margins, orientation, and paper size.
public WorksheetPageSetup WorksheetPageSetup { get; }
The worksheet page setup.