GemBox.Presentation
  • Overview
  • Examples
  • Free version
  • Support
  • Pricelist

    Show / Hide Table of Contents

    TableCell Class

    Namespace:
    GemBox.Presentation.Tables
    Assembly:
    GemBox.Presentation.dll

    Represents a table cell.

    • C#
    • VB.NET
    public sealed class TableCell : TableElement
    Public NotInheritable Class TableCell
        Inherits TableElement
    Inheritance:
    System.Object
    TableElement
    TableCell

    Properties

    ColumnSpan

    Gets or sets the number of columns through which this cell is spanning.

    • C#
    • VB.NET
    public int ColumnSpan { get; set; }
    Public Property ColumnSpan As Integer
    Property Value
    System.Int32

    The number of columns through which this cell is spanning.

    Exceptions
    System.ArgumentOutOfRangeException

    Value is less than 1.

    Format

    Gets the cell's formatting options.

    • C#
    • VB.NET
    public TableCellFormat Format { get; }
    Public ReadOnly Property Format As TableCellFormat
    Property Value
    TableCellFormat

    The cell's formatting options.

    Remarks

    This property always returns a new instance of a TableCellFormat that points to data associated with this cell. This reduces memory footprint since simpler internal structures can be used to hold the data and execution time increase is negligible since Garbage Collector has a very good performance for a short-lived (Generation 0) objects.

    Parent

    Gets the parent TableRow, if the cell is not removed; otherwise, null.

    • C#
    • VB.NET
    public TableRow Parent { get; }
    Public ReadOnly Property Parent As TableRow
    Property Value
    TableRow

    The parent TableRow, if the cell is not removed; otherwise, null.

    RowSpan

    Gets or sets the number of rows through which this cell is spanning.

    • C#
    • VB.NET
    public int RowSpan { get; set; }
    Public Property RowSpan As Integer
    Property Value
    System.Int32

    The number of rows through which this cell is spanning.

    Exceptions
    System.ArgumentOutOfRangeException

    Value is less than 1.

    Text

    Gets the text content and formatting associated with this TableCell.

    • C#
    • VB.NET
    public TextBox Text { get; }
    Public ReadOnly Property Text As TextBox
    Property Value
    TextBox

    The text content and formatting associated with this TableCell.

    TextContent

    Gets the text content of the current TableCell.

    • C#
    • VB.NET
    public TextRange TextContent { get; }
    Public ReadOnly Property TextContent As TextRange
    Property Value
    TextRange

    The text content of the current TableCell.

    Remarks

    The property always returns a new instance of the TextRange class.

    For more information, see Find and Replace example.

    Inherited Properties

    Table

    Gets the parent Table, if element is not removed; otherwise, null.

    (Inherited from TableElement)

    Examples

    Text Boxes Example
    Find and Replace example

    See Also

    Cells
    Back to top

    Facebook • Twitter • LinkedIn

    © GemBox Ltd. — All rights reserved.