Table of Contents

Method EffectiveStyle

Namespace
DocWright.Spreadsheet
Assembly
DocWright.Spreadsheet.dll

EffectiveStyle(int, int, XlsxConditionalOptions?)

Returns what a cell looks like with the sheet's conditional formats applied, as Excel draws it: its own style with the formats of the rules that hold for it laid over (the rule of the higher priority first, a stop-if-true rule ending the list), and the colour scale's fill, the data bar and the icon it gets.

public XlsxEffectiveStyle EffectiveStyle(int row, int column, XlsxConditionalOptions? options = null)

Parameters

row int

The one-based row.

column int

The one-based column.

options XlsxConditionalOptions

The date a dates-occurring rule compares with; null judges such a rule unknown.

Returns

XlsxEffectiveStyle

The effective style; IsComplete is false when a rule over the cell could not be judged.

Exceptions

ArgumentOutOfRangeException

The cell is outside the grid.

InvalidOperationException

The sheet is not a worksheet.

InvalidDocumentException

A part of the workbook is malformed.

EffectiveStyle(string, XlsxConditionalOptions?)

Returns what a cell looks like with the sheet's conditional formats applied. See EffectiveStyle(int, int, XlsxConditionalOptions?).

public XlsxEffectiveStyle EffectiveStyle(string reference, XlsxConditionalOptions? options = null)

Parameters

reference string

The cell, such as B2.

options XlsxConditionalOptions

The date a dates-occurring rule compares with; null judges such a rule unknown.

Returns

XlsxEffectiveStyle

The effective style.

Exceptions

ArgumentException

The reference is not a cell.

InvalidOperationException

The sheet is not a worksheet.

InvalidDocumentException

A part of the workbook is malformed.