Hi
I have a grid that contains a field for an email address. I need to validate that the email address at least conforms to the basic "<name>@<domain>.<tld>" format when the user enters a record.
I tried setting the type to "email" in the dataSource model, as below:
Interestingly, it worked for updates. However, when I try to create a new record, it gives the error: "Uncaught ReferenceError: Email is not defined".
My questions are:
1. Is there a way to validate a field that contains an email address in the grid?
2. Additionally, is there a way to detect a validation failure from outside the grid? I'm implementing a wizard and want to prevent the user from proceeding if they press the 'Next' button when the grid has an outstanding validation failure.
I have a grid that contains a field for an email address. I need to validate that the email address at least conforms to the basic "<name>@<domain>.<tld>" format when the user enters a record.
I tried setting the type to "email" in the dataSource model, as below:
$("#usersGrid").kendoGrid({ dataSource: { schema: { model: { id: "Id", fields: { Id: { editable: false }, Email: { type: "email", validation: { required: true} }, Username: { validation: { required: true} } } } } },
...Interestingly, it worked for updates. However, when I try to create a new record, it gives the error: "Uncaught ReferenceError: Email is not defined".
My questions are:
1. Is there a way to validate a field that contains an email address in the grid?
2. Additionally, is there a way to detect a validation failure from outside the grid? I'm implementing a wizard and want to prevent the user from proceeding if they press the 'Next' button when the grid has an outstanding validation failure.