Fill.Gradient Property
Provides access to an object containing gradient characteristics.
Namespace: DevExpress.Spreadsheet
Assembly: DevExpress.Spreadsheet.v24.2.Core.dll
NuGet Package: DevExpress.Spreadsheet.Core
Declaration
Property Value
Type | Description |
---|---|
GradientFill | A GradientFill object that contains all gradient characteristics. |
Remarks
The Gradient property affects the appearance of the cell background if the Fill.FillType is set to the Fill.Gradient
value.
- To specify the background of an individual cell, access the Fill object using the cell’s Formatting.Fill property directly.
- To specify the background of a cell range, modify the Fill object in the CellRange.BeginUpdateFormatting - CellRange.EndUpdateFormatting method pair.
- To share the same background settings between multiple cells in one step, apply the style with the specified background to the required cells. To specify the cell style background, access the Style object from the IWorkbook.Styles collection and use this style’s Formatting.Fill property within the Formatting.BeginUpdate-Formatting.EndUpdate paired methods to access and modify the Fill object.
For examples on how to specify the format for an individual cell and cell range, or modify a style, refer to the How to: Format a Cell or Range of Cells or How to: Create or Modify a Style document.
To access the Fill object, use the Formatting.Fill property.
Related GitHub Examples
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Gradient 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.