0
votes

I have an MVC application with Kendo Grid. I am using the latest Kendo 2013.1.319 which uses JQuery 1.9.1. My problem is with customizing the position and looks of validation errors of the Kendo Grid in pop up editing.
There is a sample application that deals with the validation errors server side in the KendoUI code Library "Handling server-side validation errors during pop-up editing".

This application used to work perfectly on visual studio 2010 and without updating to the latest edition of Kendo, but now it is not working with the latest edition using Visual studio 2012 and Kendo 2013.1.319

It returns an exception when trying to access the template for the error message:

Error: Syntax error, unrecognized expression: <div class="k-widget k-tooltip k-tooltip-validation k-invalid-msg field-validation-error" style="margin: 0.5em; display: block; " data-for="Name" data-valmsg-for="Name" id="Name_validationMessage">
            <span class="k-icon k-warning"> </span>My server error<div class="k-callout k-callout-n"></div></div>

in jquery.min.js file, again this wasn't the case before the upgrade.

Any help would be much appreciated.

Best regards, Sameh

1

1 Answers

0
votes

I think it has something to do with the latest jQuery version.

I found from their example, the validationMessageTmpl is already a jQuery object, so you shouldn't reparse it.

In other words, change:

.replaceWith($(validationMessageTmpl({ field: name, message: errors[0]})))

with:

.replaceWith(validationMessageTmpl({ field: name, message: errors[0]}))