This is a migrated thread and some comments may be shown as answers.

Row validation not changing when valid

3 Answers 90 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Arthur
Top achievements
Rank 1
Arthur asked on 13 Mar 2013, 06:33 PM
Hi,

I have a grid where I have set the column to valid on property changed which works fine, The red validation appears when invalid and goes when notvalid.

However, a thin red line box persists around the now valid item. I would like to

1) Either remove this secondary validation altogether
2) Would like to align the validation process of this secondary validation so that it also works on property changed



Thanks


3 Answers, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 18 Mar 2013, 04:12 PM
Hello,

May I ask you to share some more detailed information on how have you implemented the validatation? What is the invalid value you have entered - is it a value with not the right type or other (not satisfying condition defined by you)? 

All the best,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Arthur
Top achievements
Rank 1
answered on 21 Mar 2013, 03:50 PM
Hi Didie,

The validation uses IDataErrorInfo and it s checking if the data in a cell is duplicated in another cell.

The columns definition is 

 <telerik:GridViewDataColumn Header="Name" DataMemberBinding="{Binding Name}"  Width="Auto" IsReadOnly="{Binding IsReadOnly}>
                            <telerik:GridViewDataColumn.CellEditTemplate>
                                <DataTemplate>
                                    <TextBox Text="{Binding Name, UpdateSourceTrigger=PropertyChanged, NotifyOnValidationError=True, ValidatesOnDataErrors=True}" MaxLength="50" />
                                </DataTemplate>
                            </telerik:GridViewDataColumn.CellEditTemplate>
                        </telerik:GridViewDataColumn>       


When the cell is invalid it immediately has a thick red border without the need to tab. However, if I then change it to a valid value the thick red border disappears and a thin red border remains.

0
Dimitrina
Telerik team
answered on 25 Mar 2013, 11:52 AM
Hello,

I have tried to reproduce the issue, but unfortunately I were not able to. Please find attached my test project to check it at your side. 

All the best,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
GridView
Asked by
Arthur
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Arthur
Top achievements
Rank 1
Share this question
or