How can I change the validation template of the row? (See attached picture).
How can I do validation in data Source Level and paint all the border of the grid in red if there errors?
5 Answers, 1 is accepted
You can change the appearance of a row when it is either in valid or invalid states through editing the template of the row, and when the row goes into invalid state the ErrorIndicator appeared and the background of the row is changed. I recommend you to review the article as part from our online documentation that explains the Template structure of the GridViewRow. Also I have prepared an example for you that demonstrates how to modify the row and RadGridView when it goes into invalid state. Considering your second question you can achieve this effect quite easily depending on your custom scenario. You can read more about Validation mechanism that is used by RadGridView here.
Please see the attached and if you need any additional information please let me know.
the Telerik team
Hello Vanya Pavlova
Thank you this what I needed
I have tried this solution in following manner and application crashed because of a StackOverflowException.
Just do following steps:
- Make one of the columns read-only,
- Add another controler below the grid (let's say, a button...)
- Run the application ,
- Edit one of the editable fields and press enter,
- Single click on a read-only cell
- Click on the button
Thank you for the detailed description of this case. Unfortunately, we are not able to reproduce such a behavior on our side following the steps described. Can you please send us a small application via support ticket where we can see what is going on ?
the Telerik team