ClassListDataValidationRule
Validates that cell input matches one of the values in a specified list or range.
Definition
Namespace:Telerik.Windows.Documents.Spreadsheet.Model.DataValidation
Assembly:Telerik.Windows.Documents.Spreadsheet.dll
Syntax:
public sealed class ListDataValidationRule : SingleArgumentDataValidationRuleBase, IDataValidationRule
Inheritance: objectDataValidationRuleBaseSingleArgumentDataValidationRuleBaseListDataValidationRule
Implements:
Inherited Members
Constructors
ListDataValidationRule(ListDataValidationRuleContext)
Initializes a new ListDataValidationRule with the specified list source and dropdown settings.
Declaration
public ListDataValidationRule(ListDataValidationRuleContext context)
Parameters
context
The context.
Properties
InCellDropdown
Controls whether a dropdown arrow appears in the cell to display available list values.
Declaration
public bool InCellDropdown { get; set; }
Property Value
The a value indicating if an cell dropdown should be shown.
Methods
EvaluateOverride(Worksheet, int, int, ICellValue)
Evaluates whether the specified cell value matches any item in the list.
Declaration
protected override bool EvaluateOverride(Worksheet worksheet, int rowIndex, int columnIndex, ICellValue cellValue)
Parameters
worksheet
The worksheet.
rowIndex
Index of the row.
columnIndex
Index of the column.
cellValue
The cell value.
Returns
Retrurns True if the rule is satisfied, else returns False.
Overrides
ExtractListItems(Worksheet, CellIndex)
Extracts the list items defined by this rule for the specified cell location.
Declaration
public IEnumerable<string> ExtractListItems(Worksheet worksheet, CellIndex cellIndex)
Parameters
worksheet
The worksheet.
cellIndex
Index of the cell.
Returns
ExtractListItems(Worksheet, int, int)
Extracts the list items defined by this rule for the specified cell location.
Declaration
public IEnumerable<string> ExtractListItems(Worksheet worksheet, int rowIndex, int columnIndex)
Parameters
worksheet
The worksheet.
rowIndex
Index of the row.
columnIndex
Index of the column.
Returns
GetHashCode()
Serves as a hash function for a particular type.