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

[Solved] Grid Using QDSCV and validation using RIA Service

1 Answer 97 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ubuntu
Top achievements
Rank 1
Ubuntu asked on 12 Aug 2011, 02:45 PM
Dear All,
I have a simple scenario where I have a SummaryTable and DetailsTable (1-Many relation).

I am successfully displaying the data of the summary & it's details using radgrid binded directly to QDSCV that plump the data using server-side Query method.
I can add/update/ details with no problem, Now it is required to prevent duplicates at the details data for detailsID.

Simply I went to the summary metadata class and marked the navigation property to the details with the customvalidation decoration and created the validation function in .shared.cs file.

I have two remarks here:
1- The validation is executed server-side only, I mean when I hit submit (I can live with this) but I need to notify the UI about this if possible.
2- The iteration in the summary.Details is always fail as it always empty. How can I fix this?

I have followed another approach to add the customvalidation annotation on the VM at the QDSCV definition but the problem arise at the creation of the custom validator, I can't use ObservableCollection there as a parameter to my validation method.

I am frustrated to fix this problem... any help is much appreciated
Regards

1 Answer, 1 is accepted

Sort by
0
Ubuntu
Top achievements
Rank 1
answered on 15 Aug 2011, 05:11 PM
Dear All,

I should rephrase it as follows:
Q1:
Is it possible to validate the QDSCV on the VM using DataAnotation form the metadata classes?
Q2:
Is it possible to validate the QDSCV on the VM using [CustomValidation] & Validator class.?
if yes: should I implement the INotifyDataErrorInfo in my VM?

Appreciate any feedback
Regards
Tags
GridView
Asked by
Ubuntu
Top achievements
Rank 1
Answers by
Ubuntu
Top achievements
Rank 1
Share this question
or