DocumentBasePath Property
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WPF. SDK TXTextControl.from the private NuGet feed or Text Control Offline Packagesdll
Description
Gets or sets a file path that is used to search for resources like images or hypertext links. This path is added to all relative file paths used in the document.
Syntax
public string DocumentBasePath { get; set; }Public Property DocumentBasePath As StringExamples
The following example configures document settings for the current document by using DocumentSettings.DocumentBasePath.
DocumentSettings documentSettings = textControl.DocumentSettings;
documentSettings.DocumentBasePath = "document.docx";
if (!string.IsNullOrWhiteSpace(documentSettings.DocumentBasePath))
{
Console.WriteLine($"Document Base Path: {documentSettings.DocumentBasePath}");
}
documentSettings.DocumentTitle = "Quarterly results";
documentSettings.Author = "Finance team";Dim documentSettings As DocumentSettings = textControl.DocumentSettings
documentSettings.DocumentBasePath = "document.docx"
If Not String.IsNullOrWhiteSpace(documentSettings.DocumentBasePath) Then
Console.WriteLine($"Document Base Path: {documentSettings.DocumentBasePath}")
End If
documentSettings.DocumentTitle = "Quarterly results"
documentSettings.Author = "Finance team"