alexa
menu

MAUI

  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Search Results for

    Show / Hide Table of Contents

    Class FormatsCollection

    Represents collection of formats in the workbook.

    Inheritance
    object
    CommonObject
    FormatsCollection
    Implements
    IParentApplication
    IDisposable
    Inherited Members
    CommonObject.AddReference()
    CommonObject.AppImplementation
    CommonObject.Application
    CommonObject.CheckDisposed()
    CommonObject.Dispose()
    CommonObject.FindParent(object, Type)
    CommonObject.FindParent(object, Type, bool)
    CommonObject.FindParent(Type)
    CommonObject.FindParent(Type, bool)
    CommonObject.FindParent(Type[])
    CommonObject.FindParents(Type[])
    CommonObject.m_bIsDisposed
    CommonObject.OnDispose()
    CommonObject.Parent
    CommonObject.ReferenceCount
    CommonObject.ReleaseReference()
    CommonObject.SetParent(object)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Syncfusion.XlsIO.Implementation.Collections
    Assembly: Syncfusion.XlsIO.NET.dll
    Syntax
    public class FormatsCollection : CommonObject, IParentApplication, IDisposable

    Constructors

    FormatsCollection(IApplication, object)

    Initializes new instance and sets its application and parent objects.

    Declaration
    public FormatsCollection(IApplication application, object parent)
    Parameters
    Type Name Description
    IApplication application

    Application object to set.

    object parent

    Parent object to set.

    Fields

    Currency

    Represents the Currency Symbol. TODO: support currency based on the Culture.

    Declaration
    public const string Currency = "$"
    Field Value
    Type
    string

    DEFAULT_EXPONENTAIL

    Represents the default exponential.

    Declaration
    public const string DEFAULT_EXPONENTAIL = "E+"
    Field Value
    Type
    string

    Date

    Represents the index of the date format.

    Declaration
    public const string Date = "date"
    Field Value
    Type
    string

    DecimalSeparator

    Represents the Decimal Seprator.

    Declaration
    public const string DecimalSeparator = "."
    Field Value
    Type
    string

    Exponent

    Represents the Exponenet Symbol.

    Declaration
    public const string Exponent = "E"
    Field Value
    Type
    string

    Fraction

    Represents the fraction symbol.

    Declaration
    public const string Fraction = "/"
    Field Value
    Type
    string

    Minus

    Represents the Minus symbol.

    Declaration
    public const string Minus = "-"
    Field Value
    Type
    string

    Percentage

    Represents the percentage in decimal numbers.

    Declaration
    public const string Percentage = "%"
    Field Value
    Type
    string

    ThousandSeparator

    Represents the Thousand seprator.

    Declaration
    public const string ThousandSeparator = ","
    Field Value
    Type
    string

    Time

    Represents the time separator.

    Declaration
    public const string Time = ":"
    Field Value
    Type
    string

    Properties

    Count

    Gets the number of elements contained in the collection. Read-only

    Declaration
    public int Count { get; }
    Property Value
    Type
    int

    IsFixedSize

    Gets a value indicating whether the collection has a fixed size. Read-only.

    Declaration
    public bool IsFixedSize { get; }
    Property Value
    Type
    bool

    IsReadOnly

    Gets a value indicating whether the IDictionary is read-only. Read-only.

    Declaration
    public bool IsReadOnly { get; }
    Property Value
    Type
    bool

    IsSynchronized

    Gets a value indicating whether access to the collection is synchronized (thread-safe).

    Declaration
    public bool IsSynchronized { get; }
    Property Value
    Type
    bool

    this[int]

    Returns single entry from the collection. Read-only.

    Declaration
    [CLSCompliant(false)]
    public FormatImpl this[int iIndex] { get; }
    Parameters
    Type Name Description
    int iIndex
    Property Value
    Type
    FormatImpl

    this[string]

    Returns single entry from the collection by format string. Read-only.

    Declaration
    [CLSCompliant(false)]
    public FormatImpl this[string strFormat] { get; }
    Parameters
    Type Name Description
    string strFormat
    Property Value
    Type
    FormatImpl

    Keys

    Gets an ICollection containing the keys of the collection. Read-only.

    Declaration
    public ICollection Keys { get; }
    Property Value
    Type
    ICollection

    Parser

    Returns format parser. Read-only.

    Declaration
    public FormatParserImpl Parser { get; }
    Property Value
    Type
    FormatParserImpl

    SyncRoot

    Gets an object that can be used to synchronize access to the collection.

    Declaration
    public object SyncRoot { get; }
    Property Value
    Type
    object

    Values

    Declaration
    public ICollection Values { get; }
    Property Value
    Type
    ICollection

    Methods

    Add(FormatRecord)

    Adds new format to the collection.

    Declaration
    [CLSCompliant(false)]
    public void Add(FormatRecord format)
    Parameters
    Type Name Description
    FormatRecord format

    Format to add.

    AddRange(IDictionary, FormatsCollection)

    Adds format range to the collection.

    Declaration
    public Dictionary<int, int> AddRange(IDictionary dicIndexes, FormatsCollection source)
    Parameters
    Type Name Description
    IDictionary dicIndexes

    Dictionary with format indexes to add.

    FormatsCollection source

    Source collection.

    Returns
    Type Description
    Dictionary<int, int>

    Dictionary with updated indexes: key - old index, value - new index.

    Clear()

    Removes all elements from the IDictionary.

    Declaration
    public void Clear()

    Clone(object)

    Creates copy of the current instance.

    Declaration
    public FormatsCollection Clone(object parent)
    Parameters
    Type Name Description
    object parent

    Parent object for the new collection.

    Returns
    Type Description
    FormatsCollection

    Copy of the current instance.

    Contains(int)

    Determines whether the IDictionary contains an element with the specified key.

    Declaration
    public bool Contains(int key)
    Parameters
    Type Name Description
    int key

    The key to locate in the IDictionary.

    Returns
    Type Description
    bool

    True if the IDictionary contains an element with the key; otherwise, False.

    ContainsFormat(string)

    Determines whether the IDictionary contains an element with the specified format.

    Declaration
    public bool ContainsFormat(string formatString)
    Parameters
    Type Name Description
    string formatString

    Format to locate in the collection.

    Returns
    Type Description
    bool

    True if the collection contains an element with the key; otherwise, False.

    CopyTo(Array, int)

    Copies the elements of the collection to an Array, starting at a particular Array index.

    Declaration
    public void CopyTo(Array array, int index)
    Parameters
    Type Name Description
    Array array

    The one-dimensional Array that is the destination of the elements copied from ICollection. The Array must have zero-based indexing.

    int index

    The zero-based index in array at which copying begins.

    CreateFormat(string)

    Method that creates format object based on the format string and registers it in the workbook.

    Declaration
    public int CreateFormat(string formatString)
    Parameters
    Type Name Description
    string formatString

    Format string for the new format record.

    Returns
    Type Description
    int

    Index of created format.

    FindOrCreateFormat(string)

    Searches for format with specified format string and creates one if a match is not found.

    Declaration
    public int FindOrCreateFormat(string formatString)
    Parameters
    Type Name Description
    string formatString

    String describing needed format.

    Returns
    Type Description
    int

    Found or created format.

    GetEnumerator()

    Returns an IDictionaryEnumerator for the IDictionary.

    Declaration
    public IEnumerator<KeyValuePair<int, FormatImpl>> GetEnumerator()
    Returns
    Type Description
    IEnumerator<KeyValuePair<int, FormatImpl>>

    An IDictionaryEnumerator for the IDictionary.

    GetUsedFormats(ExcelVersion)

    Gets all used formats.

    Declaration
    public List<FormatRecord> GetUsedFormats(ExcelVersion version)
    Parameters
    Type Name Description
    ExcelVersion version
    Returns
    Type Description
    List<FormatRecord>

    Array that contains all used format records.

    InsertDefaultFormats()

    Inserts all default formats into list.

    Declaration
    public void InsertDefaultFormats()

    Merge(FormatsCollection)

    Copies all formats from the source collection.

    Declaration
    public Dictionary<int, int> Merge(FormatsCollection source)
    Parameters
    Type Name Description
    FormatsCollection source

    Collection to copy formats from.

    Returns
    Type Description
    Dictionary<int, int>

    Dictionary old format index - to - new format index.

    Parse(IList, int)

    Parses list of biff records.

    Declaration
    public int Parse(IList data, int iPos)
    Parameters
    Type Name Description
    IList data

    Records to parse.

    int iPos

    Offset to the format records.

    Returns
    Type Description
    int

    Position after format records.

    Remove(int)

    Removes the element with the specified key from the IDictionary.

    Declaration
    public void Remove(int key)
    Parameters
    Type Name Description
    int key

    The key of the element to remove.

    Serialize(OffsetArrayList)

    Saves formats into list of biff records.

    Declaration
    [CLSCompliant(false)]
    public void Serialize(OffsetArrayList records)
    Parameters
    Type Name Description
    OffsetArrayList records

    List to save into.

    Implements

    IParentApplication
    IDisposable
    In this article
    Back to top Generated by DocFX
    Copyright © 2001 - 2026 Syncfusion Inc. All Rights Reserved