Method AddDatesOccurring
- Namespace
- DocWright.Spreadsheet
- Assembly
- DocWright.Spreadsheet.dll
AddDatesOccurring(XlsxCellRange, XlsxTimePeriod, XlsxDifferentialStyle)
Adds a rule that formats dates in a period around today (Excel's A Date Occurring). Judged against the day Today gives.
public XlsxConditionalFormat AddDatesOccurring(XlsxCellRange range, XlsxTimePeriod period, XlsxDifferentialStyle format)
Parameters
rangeXlsxCellRangeThe cells.
periodXlsxTimePeriodThe period.
formatXlsxDifferentialStyleWhat the rule changes.
Returns
- XlsxConditionalFormat
The rule.
Exceptions
- ArgumentOutOfRangeException
The period is not one of the enumeration's values.
- ArgumentException
The format sets nothing.
- InvalidOperationException
The sheet is not a worksheet.