This is a migrated thread and some comments may be shown as answers.

Whats the formula for RANGE email validation?

1 Answer 105 Views
Spreadsheet
This is a migrated thread and some comments may be shown as answers.
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
sitefinitysteve asked on 11 May 2018, 08:02 PM

All the samples reference specific cells

https://demos.telerik.com/kendo-ui/spreadsheet/validation

The need is to be able to define validation for columns in the sheet to enforce a template... the data isn't being manually created with the sheet.  I feel like most of the samples (all?) seem to be setup with creating the row\cell on init, and that's valid for like template\header\footer setup but not real-world data usage.

sheet.range("A2:A40").validation({
                dataType: "custom",
                from: "SEARCH(\"@\")",
                allowNulls: true,
                type: "warning",
                messageTemplate: "Invalid email"
            });

1 Answer, 1 is accepted

Sort by
0
Ianko
Telerik team
answered on 15 May 2018, 11:18 AM
Hello Steve,

The SEARCH will not work for email validation. You can use NOT(ISERROR(FIND("@", A1)). Here you are a dojo example: https://dojo.telerik.com/ImuMuzur

In ranges, only one cell is needed in the formula—the first one in the range. The same will be automatically iterated. You can also validate that by examining the outputed formula in Data -> Data validation.

Regards,
Ianko
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Spreadsheet
Asked by
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
Answers by
Ianko
Telerik team
Share this question
or