Hi
Mohit,
Thanks
for using Syncfusion Products.
Grid
MVC will support Data annotation attributes. Please refer to the following code
snippets:
[EditableOrder.cs]
public class EditableOrder
{
// Validation set to the orderId
and customerId
[Required(ErrorMessage
= "Order ID is required.")]
public int OrderID
{
get;
set;
}
[Required(ErrorMessage
= "Customer ID is required.")]
[StringLength(5,
ErrorMessage = "Customer ID must be 5
characters.")]
public string
CustomerID
{
get;
set;
}
..
. .
}
Add
the following script files to your layout.cs within the head tag. Please refer
to the following code snippets:
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.js")" type="text/javascript"></script>
We
have prepared the sample for your requirement and the same can be downloaded
from the following link:
http://www.syncfusion.com/downloads/Support/DirectTrac/89849/Editing1742303737.zip
Also we would request you to check the following online sample link:
http://mvc.syncfusion.com/demos/ui/grid/Editing/CellEditType#
Please
try this and let us know if you have any other queries.
Regards,
Gowri.S