Update Method
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WPF. SDK TXTextControl.from the private NuGet feed or Text Control Offline Packagesdll
Description
Updates the content and the page numbers of the table of contents.
Syntax
public TableOfContentsCollection.AddResult Update();Public Function Update() As TableOfContentsCollection.AddResultReturn Value
The return value specifies whether the new table of contents has successfully been updated. It can be one of the TableOfContentsCollection.AddResult values.
Examples
The following example creates a table of contents for the document's heading styles by using TableOfContents.Update.
TableOfContents tableOfContents = new(1, 3) { Name = "Contents", ID = 10 };
textControl.TablesOfContents.Add(tableOfContents);
var result = tableOfContents.Update();
Console.WriteLine($"Update result: {result}");Dim tableOfContents As New TableOfContents(1, 3) With { .Name = "Contents", .ID = 10 }
textControl.TablesOfContents.Add(tableOfContents)
Dim result = tableOfContents.Update()
Console.WriteLine($"Update result: {result}")