IMPORTANT: This version of Sitefinity CMS is out of support and the respective product documentation is no longer maintained and can be outdated. Use the version selector to view a supported product version.
PREREQUISITES: You have enabled the AJAX submit call functionality for the Forms module. For more information, see Submit forms using AJAX call.
The following interface is implemented by all events raised before a form is validated. There is only one such built-in event FormValidatingEvent and you must subscribe to the interface rather than the class that implements it. Subscribe to the event using the following code:
The above example demonstrates how to check for invalid input. As a result, if you attempt to submit the form with a value that does not match the validation criteria, an error message The 'Name' field must consist of two words. is displayed.
In the event handler, you can access the following information:
This interface is implemented by the FormFieldValidatingEvent and is raised when a form field is validated. Subscribe to the event using the following code:
This interface is a contract for events that contain all form data. The interface inherits the IFormModuleEvent. The IFormEvent is implemented by the following events:
NOTE: If an action is cancelled, the event handlers throw Telerik.Sitefinity.Services.Events.CancelationException.
Anytime an action related to forms is executed, the IFormEvent is raised. To subscribe to the event, use the following code:
Back To Top
To submit feedback, please update your cookie settings and allow the usage of Functional cookies.
Your feedback about this content is important