Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

ExcelColumnFormatPlan

OfficeIMO.Excel

Namespace
OfficeIMO.Excel
Assembly
OfficeIMO.Excel
Source revision
0eef6a5756b9 with working tree changes
Modifiers
sealed

Describes reusable header-based column number formats for worksheet exports.

Inheritance

  • object
  • ExcelColumnFormatPlan

Usage

Explore 11 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 1

Constructors

public ExcelColumnFormatPlan() #

Methods

public ExcelColumnFormatPlan Add(string header, ExcelNumberPreset preset, int decimals = 2, CultureInfo? culture = null, bool includeHeader = false, bool autoFit = false) #

Adds a preset number format for a column resolved by header text.

Parameters

header string required
preset OfficeIMO.Excel.ExcelNumberPreset required
decimals int = 2 optional
culture System.Globalization.CultureInfo? = null optional
includeHeader bool = false optional
autoFit bool = false optional
public ExcelColumnFormatPlan AddFormat(string header, string numberFormat, bool includeHeader = false, bool autoFit = false) #

Adds a custom Excel number format for a column resolved by header text.

Parameters

header string required
numberFormat string required
includeHeader bool = false optional
autoFit bool = false optional
Currency 4 overloads
public ExcelColumnFormatPlan Currency(params string[] headers) #

Adds currency formatting for columns resolved by header text.

Parameters

headers string[] required
public ExcelColumnFormatPlan Currency(CultureInfo? culture, params string[] headers) #

Adds culture-aware currency formatting for columns resolved by header text.

Parameters

culture System.Globalization.CultureInfo? required
headers string[] required
public ExcelColumnFormatPlan Currency(int decimals, params string[] headers) #

Adds currency formatting with explicit precision for columns resolved by header text.

Parameters

decimals int required
headers string[] required
public ExcelColumnFormatPlan Currency(int decimals, CultureInfo? culture, params string[] headers) #

Adds culture-aware currency formatting with explicit precision for columns resolved by header text.

Parameters

decimals int required
culture System.Globalization.CultureInfo? required
headers string[] required
public ExcelColumnFormatPlan Date(params string[] headers) #

Adds date formatting for columns resolved by header text.

Parameters

headers string[] required
public ExcelColumnFormatPlan DateTime(params string[] headers) #

Adds date and time formatting for columns resolved by header text.

Parameters

headers string[] required
public ExcelColumnFormatPlan Integer(params string[] headers) #

Adds integer formatting for columns resolved by header text.

Parameters

headers string[] required
Number 2 overloads
public ExcelColumnFormatPlan Number(params string[] headers) #

Adds decimal number formatting for columns resolved by header text.

Parameters

headers string[] required
public ExcelColumnFormatPlan Number(int decimals, params string[] headers) #

Adds decimal number formatting with explicit precision for columns resolved by header text.

Parameters

decimals int required
headers string[] required
Percent 2 overloads
public ExcelColumnFormatPlan Percent(params string[] headers) #

Adds percent formatting for columns resolved by header text.

Parameters

headers string[] required
public ExcelColumnFormatPlan Percent(int decimals, params string[] headers) #

Adds percent formatting with explicit precision for columns resolved by header text.

Parameters

decimals int required
headers string[] required
public ExcelColumnFormatPlan Text(params string[] headers) #

Adds text formatting for columns resolved by header text.

Parameters

headers string[] required

Properties

public IReadOnlyList<ExcelColumnFormatRule> Rules { get; } #

Gets the configured column format rules.

public int Count { get; } #

Gets the number of configured rules.