Returns or sets the inner text of the text range.

Namespace:  C1.Win.XmlEditor
Assembly:  C1.Win.XmlEditor.2 (in C1.Win.XmlEditor.2.dll)

Syntax

C#
public string Text { get; set; }
Visual Basic (Declaration)
Public Property Text As String

Examples

This code demonstrates the Text and the XmlText properties.
Copy CodeC#
privatevoid button1_Click(object sender, EventArgs e)
{
    c1XmlEditor1.LoadXml("<html><head><title>Document</title></head><body><p>12<span>3</span>456</p></body></html>", new Uri("c:\\"));
    C1TextRange r = c1XmlEditor1.CreateRange();
    r.Move(1, 3);
    Console.WriteLine(r.Text);
    // Output: 234
    Console.WriteLine(r.XmlText);
    // Output: <p xmlns="http://www.w3.org/1999/xhtml">2<span>3</span>4</p>
    r.XmlText = "<div style=\"border: solid 1px black\">New Text</div>";
    Console.WriteLine(c1XmlEditor1.Text);
    //Output://1//NewText//56
}

See Also