GemBox.Spreadsheet by GemBox Software

<PackageReference Include="GemBox.Spreadsheet" Version="39.3.30.1129" />

.NET API 2,455,552 bytes

 DataValidation

public sealed class DataValidation
A single item of data validation defined on ranges of the worksheet.

Gets the ranges over which data validation is applied.

public string ErrorMessage { get; set; }

Gets or sets the message text of error alert.

public DataValidationErrorStyle ErrorStyle { get; set; }

Gets or sets the style of error alert used for this data validation.

public string ErrorTitle { get; set; }

Gets or sets the title bar text of error alert.

public object Formula1 { get; set; }

Gets or sets the first formula in the DataValidation dropdown.

public object Formula2 { get; set; }

Gets or sets the second formula in the DataValidation dropdown.

public bool IgnoreBlank { get; set; }

Gets or sets a value indicating whether the data validation treats empty or blank entries as valid. true means empty entries are OK and do not violate the validation constraints.

public bool InCellDropdown { get; set; }

Gets or sets a value indicating whether to display the dropdown combo box for a List data validation type.

public string InputMessage { get; set; }

Gets or sets the message text of input prompt.

public string InputMessageTitle { get; set; }

Gets or sets the title bar text of input prompt.

public DataValidationOperator Operator { get; set; }

Gets or sets the relational operator used with this data validation.

public bool ShowErrorAlert { get; set; }

Gets or sets a value indicating whether to display the error alert message when an invalid value has been entered, according to the criteria specified.

public bool ShowInputMessage { get; set; }

Gets or sets a value indicating whether to display the input prompt message.

public DataValidationType Type { get; set; }

Gets or sets the type of data validation.

public DataValidation()

Initializes a new instance of the DataValidation class.

public DataValidation(ExcelWorksheet worksheet, IEnumerable<string> cellReferences)

Initializes a new instance of the DataValidation class with specified worksheet and cell references on which this data validation will be applied.

public DataValidation(ExcelWorksheet worksheet, string[] cellReferences)

Initializes a new instance of the DataValidation class with specified worksheet and cell references on which this data validation will be applied.

public DataValidation(IEnumerable<CellRange> cellRanges)

Initializes a new instance of the DataValidation class with specified cell ranges on which this data validation will be applied.

public DataValidation(CellRange[] cellRanges)

Initializes a new instance of the DataValidation class with specified cell ranges on which this data validation will be applied.