MsExpressionEdit.OnUpdateFormula

Syntax

OnUpdateFormula(Sender: IMsExpressionEdit; Args: ITermEventArgs);

Parameters

Sender. Component that has generated the event.

Args. Event arguments.

Description

The OnUpdateFormula event that occurs on converting the external presentation of expression to the internal one.

Comments

The OnUpdateFormula event is called for the literal terms, the formula and the text of which match. It enables the user to set the internal view to the external one.

The converting of external view of the term to the internal one occurs, for example, on entering or changing the text in the MsExpressionEdit component.

Example

Executing the example requires a form and the MsExpressionEdit component with the MsExpressionEdit1 identifier.

The example is a handler of the OnUpdateFormula event for the MsExpressionEdit1 component.

Sub MsExpressionEdit1OnUpdateFormula(Sender: IMsExpressionEdit; Args: ITermEventArgs);
Begin
    If Args.Term = Null Then
        Return;
    End If;
    Args.Term.IsHyperlink := True;
    debug.WriteLine(Expression delimiters:  + Sender.HeavyDelimiters + );
    debug.WriteLine(Words delimiter in the expression:  + Sender.LightDelimiters + );
    debug.WriteLine(Maximum number of words in the expression:  + Sender.MaxTermWordCount.ToString + );
End Sub MsExpressionEdit1OnUpdateFormula;

After executing the example the expression separators data, the words separators in the expression data and the maximum number of words in the expression data is displayed in the console window. Expressions are displayed as hyperlinks.

See also:

MsExpressionEdit