menu

Document Processing

ExtendedFormatWrapper Class - C# Excel Library API Reference | Syncfusion

    Show / Hide Table of Contents

    ExtendedFormatWrapper Class

    This class wraps extended format inside in order to hide from user creation of new extended formats when user changes any properties of extended format.

    Inheritance
    System.Object
    CommonWrapper
    ExtendedFormatWrapper
    CellStyle
    StyleImpl
    Implements
    IXFIndex
    IStyle
    IExtendedFormat
    IParentApplication
    IOptimizedUpdate
    ICloneParent
    Inherited Members
    CommonWrapper.BeginCallsCount
    Namespace: Syncfusion.XlsIO.Implementation
    Assembly: Syncfusion.XlsIO.Base.dll
    Syntax
    public class ExtendedFormatWrapper : CommonWrapper, IInternalExtendedFormat, IXFIndex, IStyle, IExtendedFormat, IParentApplication, IOptimizedUpdate, ICloneParent

    Constructors

    ExtendedFormatWrapper(WorkbookImpl)

    Creates new instance of extended format wrapper.

    Declaration
    public ExtendedFormatWrapper(WorkbookImpl book)
    Parameters
    Type Name Description
    WorkbookImpl book

    ExtendedFormatWrapper(WorkbookImpl, Int32)

    Creates new instance of extended format wrapper.

    Declaration
    public ExtendedFormatWrapper(WorkbookImpl book, int iXFIndex)
    Parameters
    Type Name Description
    WorkbookImpl book

    Parent workbook.

    System.Int32 iXFIndex

    Index of extended format to wrap.

    Fields

    m_book

    Parent workbook.

    Declaration
    protected WorkbookImpl m_book
    Field Value
    Type
    WorkbookImpl

    m_font

    Font wrapper.

    Declaration
    protected FontWrapper m_font
    Field Value
    Type
    FontWrapper

    m_xFormat

    Extended format with style settings.

    Declaration
    protected ExtendedFormatImpl m_xFormat
    Field Value
    Type
    ExtendedFormatImpl

    Properties

    Application

    Reference to Application which hosts all objects. Read-only.

    Declaration
    public IApplication Application { get; }
    Property Value
    Type
    IApplication

    Borders

    Returns borders object for this extended format.

    Declaration
    public IBorders Borders { get; }
    Property Value
    Type
    IBorders

    BottomBorderColor

    Get/set BottomBorder color.

    Declaration
    public virtual ColorObject BottomBorderColor { get; }
    Property Value
    Type
    ColorObject

    BottomBorderLineStyle

    Gets / sets line style of the bottom border.

    Declaration
    public virtual ExcelLineStyle BottomBorderLineStyle { get; set; }
    Property Value
    Type
    ExcelLineStyle

    BuiltIn

    Indicates whether style is build in. Read-only.

    Declaration
    public bool BuiltIn { get; }
    Property Value
    Type
    System.Boolean

    Color

    Returns or sets the cell shading color.

    Declaration
    public Color Color { get; set; }
    Property Value
    Type
    System.Drawing.Color

    ColorIndex

    Returns or sets the color of the interior. The color is specified as an index value into the current color palette.

    Declaration
    public ExcelKnownColors ColorIndex { get; set; }
    Property Value
    Type
    ExcelKnownColors

    DiagonalBorderColor

    Get/set DiagonalUpBorder color.

    Declaration
    public ColorObject DiagonalBorderColor { get; }
    Property Value
    Type
    ColorObject

    DiagonalDownBorderLineStyle

    Gets / sets line style of the diagonal border.

    Declaration
    public ExcelLineStyle DiagonalDownBorderLineStyle { get; set; }
    Property Value
    Type
    ExcelLineStyle

    DiagonalDownVisible

    Indicates whether DiagonalDown line is visible.

    Declaration
    public bool DiagonalDownVisible { get; set; }
    Property Value
    Type
    System.Boolean

    DiagonalUpBorderLineStyle

    Gets / sets line style of the diagonal border.

    Declaration
    public ExcelLineStyle DiagonalUpBorderLineStyle { get; set; }
    Property Value
    Type
    ExcelLineStyle

    DiagonalUpVisible

    Indicates whether DiagonalUp line is visible.

    Declaration
    public bool DiagonalUpVisible { get; set; }
    Property Value
    Type
    System.Boolean

    FillBackground

    Gets / Sets index of fill background color.

    Declaration
    public ExcelKnownColors FillBackground { get; set; }
    Property Value
    Type
    ExcelKnownColors

    FillBackgroundRGB

    Gets / Sets fill background color.

    Declaration
    public Color FillBackgroundRGB { get; set; }
    Property Value
    Type
    System.Drawing.Color

    FillForeground

    Gets / Sets index of fill foreground color.

    Declaration
    public ExcelKnownColors FillForeground { get; set; }
    Property Value
    Type
    ExcelKnownColors

    FillForegroundRGB

    Gets / Sets fill foreground color.

    Declaration
    public Color FillForegroundRGB { get; set; }
    Property Value
    Type
    System.Drawing.Color

    FillPattern

    Gets / Sets fill pattern.

    Declaration
    public ExcelPattern FillPattern { get; set; }
    Property Value
    Type
    ExcelPattern

    Font

    Returns font object for this extended format.

    Declaration
    public IFont Font { get; }
    Property Value
    Type
    IFont

    FontIndex

    Gets / Sets font index.

    Declaration
    public int FontIndex { get; set; }
    Property Value
    Type
    System.Int32

    FormulaHidden

    True if formula is hidden.

    Declaration
    public bool FormulaHidden { get; set; }
    Property Value
    Type
    System.Boolean

    HasBorder

    Gets or sets whether the extended format has border

    Declaration
    public bool HasBorder { get; }
    Property Value
    Type
    System.Boolean

    HorizontalAlignment

    Horizontal alignment.

    Declaration
    public ExcelHAlign HorizontalAlignment { get; set; }
    Property Value
    Type
    ExcelHAlign

    IncludeAlignment

    True if the style includes the AddIndent, HorizontalAlignment, VerticalAlignment, WrapText, and Orientation properties. Read / write Boolean.

    Declaration
    public bool IncludeAlignment { get; set; }
    Property Value
    Type
    System.Boolean

    IncludeBorder

    True if the style includes the Color, ColorIndex, LineStyle, and Weight border properties. Read / write Boolean.

    Declaration
    public bool IncludeBorder { get; set; }
    Property Value
    Type
    System.Boolean

    IncludeFont

    True if the style includes the Background, Bold, Color, ColorIndex, FontStyle, Italic, Name, OutlineFont, Shadow, Size, Strikethrough, Subscript, Superscript, and Underline font properties. Read / write Boolean.

    Declaration
    public bool IncludeFont { get; set; }
    Property Value
    Type
    System.Boolean

    IncludeNumberFormat

    True if the style includes the NumberFormat property. Read / write Boolean.

    Declaration
    public bool IncludeNumberFormat { get; set; }
    Property Value
    Type
    System.Boolean

    IncludePatterns

    True if the style includes the Color, ColorIndex, InvertIfNegative, Pattern, PatternColor, and PatternColorIndex interior properties. Read / write Boolean.

    Declaration
    public bool IncludePatterns { get; set; }
    Property Value
    Type
    System.Boolean

    IncludeProtection

    True if the style includes the FormulaHidden and Locked protection properties. Read / write Boolean.

    Declaration
    public bool IncludeProtection { get; set; }
    Property Value
    Type
    System.Boolean

    IndentLevel

    Indent level.

    Declaration
    public int IndentLevel { get; set; }
    Property Value
    Type
    System.Int32

    Interior

    Returns interior object for this extended format.

    Declaration
    public IInterior Interior { get; }
    Property Value
    Type
    IInterior

    IsFirstSymbolApostrophe

    If true then first symbol in cell is apostrophe.

    Declaration
    public bool IsFirstSymbolApostrophe { get; set; }
    Property Value
    Type
    System.Boolean

    IsInitialized

    Indicates whether style is initialized (differs from Normal style). Read-only.

    Declaration
    public bool IsInitialized { get; }
    Property Value
    Type
    System.Boolean

    IsModified

    Gets value indicating whether format was modified, compared to parent format.

    Declaration
    public bool IsModified { get; }
    Property Value
    Type
    System.Boolean

    JustifyLast

    For far east languages. Supported only for format. Always 0 for US.

    Declaration
    public bool JustifyLast { get; set; }
    Property Value
    Type
    System.Boolean

    LeftBorderColor

    Get/set LeftBorder color.

    Declaration
    public virtual ColorObject LeftBorderColor { get; }
    Property Value
    Type
    ColorObject

    LeftBorderLineStyle

    Gets / sets line style of the left border.

    Declaration
    public virtual ExcelLineStyle LeftBorderLineStyle { get; set; }
    Property Value
    Type
    ExcelLineStyle

    Locked

    True if cell is locked.

    Declaration
    public bool Locked { get; set; }
    Property Value
    Type
    System.Boolean

    Name

    Returns name of the style. Read-only.

    Declaration
    public string Name { get; }
    Property Value
    Type
    System.String

    NumberFormat

    Returns or sets the format code for the object. Read / write String.

    Declaration
    public string NumberFormat { get; set; }
    Property Value
    Type
    System.String

    NumberFormatIndex

    Gets / Sets format index.

    Declaration
    public int NumberFormatIndex { get; set; }
    Property Value
    Type
    System.Int32

    NumberFormatLocal

    Returns or sets the format code for the object as a string in the language of the user. Read / write String.

    Declaration
    public string NumberFormatLocal { get; set; }
    Property Value
    Type
    System.String

    NumberFormatSettings

    Returns object that describes number format. Read-only.

    Declaration
    public INumberFormat NumberFormatSettings { get; }
    Property Value
    Type
    INumberFormat

    Parent

    Reference to Parent object. Read-only.

    Declaration
    public object Parent { get; }
    Property Value
    Type
    System.Object

    PatternColor

    Returns or sets the color of the interior pattern as an Color value.

    Declaration
    public Color PatternColor { get; set; }
    Property Value
    Type
    System.Drawing.Color

    PatternColorIndex

    Returns or sets the color of the interior pattern as an index into the current color palette.

    Declaration
    public ExcelKnownColors PatternColorIndex { get; set; }
    Property Value
    Type
    ExcelKnownColors

    ReadingOrder

    Text direction, the reading order for far east versions.

    Declaration
    public ExcelReadingOrderType ReadingOrder { get; set; }
    Property Value
    Type
    ExcelReadingOrderType

    RightBorderColor

    Get/set RightBorder color.

    Declaration
    public virtual ColorObject RightBorderColor { get; }
    Property Value
    Type
    ColorObject

    RightBorderLineStyle

    Gets / sets line style of the right border.

    Declaration
    public virtual ExcelLineStyle RightBorderLineStyle { get; set; }
    Property Value
    Type
    ExcelLineStyle

    Rotation

    Text rotation angle: 0 Not rotated 1-90 1 to 90 degrees counterclockwise 91-180 1 to 90 degrees clockwise 255 Letters are stacked top-to-bottom, but not rotated.

    Declaration
    public int Rotation { get; set; }
    Property Value
    Type
    System.Int32
    Exceptions
    Type Condition
    System.ArgumentOutOfRangeException

    Thrown when value is more than 0xFF.

    ShrinkToFit

    True - shrink content to fit into cell.

    Declaration
    public bool ShrinkToFit { get; set; }
    Property Value
    Type
    System.Boolean

    TopBorderColor

    Get/set TopBorder color.

    Declaration
    public virtual ColorObject TopBorderColor { get; }
    Property Value
    Type
    ColorObject

    TopBorderLineStyle

    Gets / sets line style of the top border.

    Declaration
    public virtual ExcelLineStyle TopBorderLineStyle { get; set; }
    Property Value
    Type
    ExcelLineStyle

    VerticalAlignment

    Vertical alignment.

    Declaration
    public ExcelVAlign VerticalAlignment { get; set; }
    Property Value
    Type
    ExcelVAlign

    Workbook

    Returns parent workbook. Read-only.

    Declaration
    public WorkbookImpl Workbook { get; }
    Property Value
    Type
    WorkbookImpl

    Wrapped

    Returns wrapped format.

    Declaration
    public ExtendedFormatImpl Wrapped { get; }
    Property Value
    Type
    ExtendedFormatImpl

    WrapText

    True - Text is wrapped at right border.

    Declaration
    public bool WrapText { get; set; }
    Property Value
    Type
    System.Boolean

    XFormatIndex

    Gets format index in m_book.InnerFormats.

    Declaration
    public int XFormatIndex { get; }
    Property Value
    Type
    System.Int32

    Methods

    BeforeRead()

    This method is called before reading any value. Can be used to update wrapped object before read operation.

    Declaration
    protected virtual void BeforeRead()

    BeginUpdate()

    This method should be called before several updates to the object will take place.

    Declaration
    public override void BeginUpdate()
    Overrides
    CommonWrapper.BeginUpdate()

    ChangeFillPattern()

    Sets solid fill pattern when changing

    Declaration
    public void ChangeFillPattern()

    Clone(Object)

    Declaration
    public override object Clone(object parent)
    Parameters
    Type Name Description
    System.Object parent
    Returns
    Type
    System.Object
    Overrides
    CommonWrapper.Clone(Object)

    EndUpdate()

    This method should be called after several updates to the object took place.

    Declaration
    public override void EndUpdate()
    Overrides
    CommonWrapper.EndUpdate()

    OnNumberFormatChange()

    This method is called after changes in NumberFormat.

    Declaration
    protected void OnNumberFormatChange()

    SetChanged()

    Sets Saved flag of the parent workbook to the False. Called when any changes occurred in the style.

    Declaration
    protected void SetChanged()

    SetFormatIndex(Int32)

    Creates inner extended format.

    Declaration
    public void SetFormatIndex(int index)
    Parameters
    Type Name Description
    System.Int32 index

    Index to extended format to wrap.

    SetParents(Object)

    Searches for all necessary parent objects.

    Declaration
    protected virtual void SetParents(object parent)
    Parameters
    Type Name Description
    System.Object parent

    Parent object.

    UpdateFont()

    Updates inner extended format's font wrapper.

    Declaration
    public void UpdateFont()

    Events

    NumberFormatChanged

    Event is raised after changes in number format.

    Declaration
    public event EventHandler NumberFormatChanged
    Event Type
    Type
    System.EventHandler

    Implements

    IXFIndex
    IStyle
    IExtendedFormat
    IParentApplication
    IOptimizedUpdate
    ICloneParent
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved