ValidationCollection

ValidationCollection class

Represents data validation collection.

class ValidationCollection;

Methods

MethodDescription
get(number)Gets the Validation element at the specified index.
add(CellArea)Adds a data validation to the collection.
removeACell(number, number)Removes all validation setting on the cell.
removeArea(CellArea)Removes all validation setting on the range..
getValidationInCell(number, number)Gets the validation applied to given cell.
getCount()@deprecated. Please use the ‘count’ property instead. Gets the number of elements contained in.
isNull()Checks whether the implementation object is null.

get(number)

Gets the Validation element at the specified index.

get(index: number) : Validation;

Parameters:

ParameterTypeDescription
indexnumberThe zero based index of the element.

Returns

The element at the specified index.

add(CellArea)

Adds a data validation to the collection.

add(ca: CellArea) : number;

Parameters:

ParameterTypeDescription
caCellAreaThe area contains this validation.

Returns

Validation object index.

removeACell(number, number)

Removes all validation setting on the cell.

removeACell(row: number, column: number) : void;

Parameters:

ParameterTypeDescription
rownumberThe row index of the cell.
columnnumberThe column index of the cell.

removeArea(CellArea)

Removes all validation setting on the range..

removeArea(ca: CellArea) : void;

Parameters:

ParameterTypeDescription
caCellAreaThe range which contains the validations setting.

getValidationInCell(number, number)

Gets the validation applied to given cell.

getValidationInCell(row: number, column: number) : Validation;

Parameters:

ParameterTypeDescription
rownumberThe row index.
columnnumberThe column index.

Returns

Returns a Validation object or null if there is no validation for given cell

getCount()

@deprecated. Please use the ‘count’ property instead. Gets the number of elements contained in.

getCount() : number;

isNull()

Checks whether the implementation object is null.

isNull() : boolean;