New to Telerik UI for WinForms? Start a free 30-day trial

Stores calculator values, operation metadata, and formatted history for an undo/redo entry.

Definition

Namespace:Telerik.WinControls.UI.Calculator

Assembly:Telerik.WinControls.UI.dll

Syntax:

C#
public class StatusItem

Inheritance: objectStatusItem

Constructors

Initializes an empty calculator status entry.

C#
public StatusItem()

Initializes a status entry with a calculated value and its associated operation.

C#
public StatusItem(decimal calculatedValueStatus, Operation operationStatus)
Parameters:calculatedValueStatusdecimal

The calculated value captured by the entry.

operationStatusOperation

The operation represented by the entry.

Properties

Gets or sets the calculated value saved for this history entry.

C#
public decimal CalculatedValueStatus { get; set; }

Gets or sets the formatted history text, creating its builder on first access.

C#
public StringBuilder HistoryStatus { get; set; }

Gets or sets the operation used when restoring this history entry.

C#
public Operation OperationStatus { get; set; }

Gets or sets the leading fragment used to build this entry's history text.

C#
public string PartA { get; set; }

Gets or sets the trailing fragment used to build this entry's history text.

C#
public string PartB { get; set; }

Methods

Builds this entry's history text from an operation and input, continuing the expression when a previous entry is supplied.

C#
public void FormatHistoryStatus(StatusItem previousStatusItem, Operation operation, decimal inputValue, bool isOperationExecuted)
Parameters:previousStatusItemStatusItem

The preceding history entry, or null to start a new expression.

operationOperation

The operation to represent in the history text.

inputValuedecimal

The value used to format the operation's history fragment.

isOperationExecutedbool

true when the preceding operation has already been executed.