TX Text Control .NET Server

DialogResult Enumeration

Enumeration
Namespace
TXTextControl.DocumentServer.Fields
Full name
TXTextControl.DocumentServer.Fields.DialogResult
Package
TXTextControl.TextControl.Core.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXDocumentServer.Core.dll
Install
dotnet add package TXTextControl.TextControl.Core.SDK .NET 8 and later. For .NET Framework, reference TXDocumentServer.dll from the setup.
Also in
TXTextControl.TextControl.ASP.SDK as TXDocumentServer.dll

Description

Specifies identifiers to indicate the return value of a dialog box.

Syntax

public enum DialogResult

Members

MemberValueDescription
None0Nothing is returned from the dialog box. This means that the modal dialog continues running.
OK1The dialog box return value is OK (usually sent from a button labeled OK).
Cancel2The dialog box return value is Cancel (usually sent from a button labeled Cancel).

Examples

DocumentServer.DataSources.DialogResult is not exposed by the current SDK. Field-adapter dialogs now return DocumentServer.Fields.DialogResult. The following example handles a canceled field-mapping dialog without applying changes.

TXTextControl.DocumentServer.Fields.DialogResult result =
    TXTextControl.DocumentServer.Fields.DialogResult.Cancel;

if (result == TXTextControl.DocumentServer.Fields.DialogResult.Cancel)
{
    Console.WriteLine("The field mapping was not changed.");
}