Method AddDataBar
- Namespace
- DocWright.Spreadsheet
- Assembly
- DocWright.Spreadsheet.dll
AddDataBar(XlsxCellRange, ColorRgb?)
Adds a data bar from the lowest value to the highest, as Excel's Data Bars do, with Excel 2010's settings (bars from 0 to 100 percent of the cell).
public XlsxConditionalFormat AddDataBar(XlsxCellRange range, ColorRgb? color = null)
Parameters
rangeXlsxCellRangeThe cells.
colorColorRgb?The bar's colour; null for Excel's blue (
638EC6).
Returns
- XlsxConditionalFormat
The rule.
Exceptions
- InvalidOperationException
The sheet is not a worksheet.