Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

OdsDataStyle

OfficeIMO.OpenDocument

Namespace
OfficeIMO.OpenDocument
Assembly
OfficeIMO.OpenDocument
Source revision
be6c300e4ab1 with working tree changes
Modifiers
sealed

An XML-backed ODS number, percentage, currency, date, or time style.

Inheritance

  • object
  • OdsDataStyle

Usage

Explore 6 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.

Methods

public string ToExcelNumberFormatCode() #

Projects the represented common ODF style to an Excel number-format code.

Returns

string

Exceptions

  • InvalidOperationException – The style cannot be represented within Excel's custom-format limit.
public bool TryGetExcelNumberFormatCode(out string formatCode) #

Attempts to project the represented common ODF style to a bounded Excel number-format code.

Parameters

formatCode string required

Returns

bool

Properties

public string Name { get; } #

Style name referenced by a cell style.

public OdsDataStyleKind Kind { get; } #

Data style kind.

public int DecimalPlaces { get; } #

Configured decimal places, or zero when the style has no decimal number component.

public int MinimumIntegerDigits { get; } #

Minimum integer digits requested by the number component.

public bool UsesGrouping { get; } #

Whether the style requests grouped thousands.

public string? CurrencySymbol { get; } #

Visible currency symbol or code, when present.

Fields

public const int MaximumExcelNumberFormatCodeLength #

Maximum number of characters supported by an Excel custom number-format code.

Value: 255