TX Text Control .NET Server

TextType Property

Property|Introduced in 26.0
Namespace
TXTextControl
Package
TXTextControl.TextControl.Core.SDK as TXTextControl.Core.dll from the private NuGet feed or Text Control Offline Packages
Also in
TXTextControl.TextControl.ASP.SDK as TXTextControl.dll

Description

Gets or sets the text type of the table cell which determines whether the cell's text is interpreted as a number or as text When the type is Standard, the cell's text is interpreted as text and it is displayed as it is. When the type is Number, the cell's text is interpreted as a number. The period character (.) is defined as decimal separator, the comma character (,) is defined as thousands separator.

Syntax

public TextType TextType { get; set; }

Members

ValueDescription
StandardThe text is displayed as it is.
NumberThe text is interpreted as a number. The period character (.) is defined as decimal separator, the comma character (,) is defined as thousands separator.

Examples

The following example creates a small report table and works with its structure by using TableCellFormat.TextType.

textControl.Tables.Add(3, 3, 10);
Table table = textControl.Tables.GetItem(10);
TableCellFormat tableCellFormat = table.Cells[1, 1].CellFormat;

tableCellFormat.TextType = TextType.Standard;
Console.WriteLine($"Text Type used by Table Cell Format: {tableCellFormat.TextType}");

Further Reading

  • Formatting Numbers in Table Cells –