jQuery UI Widgets › Forums › Grid › Is a form required for jqxValidator?
Tagged: jqxgrid, jqxvalidator
This topic contains 4 replies, has 2 voices, and was last updated by Ivo Zhulev 10 years, 1 month ago.
-
Author
-
Its not explicit in the documentation, but it seems pretty clear from the examples that a form is required. I need to validate the cells in a grid. Is there another way to manually validate entries?
ThanksHi lorenzopt,
Please take a look at this demo :
http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/cellediting.htm?lightBest Regards,
IvojQWidgets Team
http://www.jqwidgets.com/Thanks for the reply, I did look at this demo, but I was never able to get the validation function called. Let me provide a little background: We have a jqxgrid with jqx widgets, checkboxes, textfields and dropdowns populating the cells. The validation needs to occurs on the values and selections in these widgets when the widget loses focus. I call begincelledit on the cell when a widget gets focus, but when the widget loses focus, the validation function is not called. I’ve taken that to mean that the grid does not ‘see’ the focus being lost, since focus is on the widget, not the cell itself, therefore, the validation function is not called. That’s why I tried manual validation. This works, but it requires a form, which we don’t need but it its required, we’ll have to work with it.
Thanks again.So, I figured it out. No a form is not required. I applied the validator to the widget element that gets inserted into the grid cell. The validator is then invoked using the id of the target element.
But I do have one more question:
Is there a hook that allows me to display my own error element? We need to ensure for ADA purposes that the error popup is ADA compliant.
ThanksHi lorenzopt,
You can edit the classes that style the popup :
.jqx-grid-validationand.jqx-grid-validation-arrow-upBest Regards,
IvojQWidgets Team
http://www.jqwidgets.com/ -
AuthorPosts
You must be logged in to reply to this topic.