RadGridView and the DataFormValidationSummary

8 posts, 0 answers
  1. Steve
    Steve avatar
    124 posts
    Member since:
    Jun 2011

    Posted 08 Jul 2013 Link to this post

    Hi,
    Is there any way to integrate the DataFormValidationSummary control with the RadGridView?
    Thanks in advance,
    Steve
  2. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 09 Jul 2013 Link to this post

    Hello Steve,

    Will it be possible to carify what the exact behavior you want to get is ? Do you want just to display the errors in a separate control below the grid for example ? 

    Regards,
    Maya
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. UI for WPF is Visual Studio 2017 Ready
  4. Steve
    Steve avatar
    124 posts
    Member since:
    Jun 2011

    Posted 09 Jul 2013 Link to this post

    Yes, in as a separate control under the grid, as it is with the data form.  The main thing is how to map the grid validation to it.
    Thanks,
    Steve
  5. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 11 Jul 2013 Link to this post

    Hello Steve,

    You will need to expose a collection property to keep track of the errors in the grid and bind it to the validation summary. However, you can just create an ItemsControl for example and bind it to those errors without the need to work with DataFormValidationSummary. 

    Regards,
    Maya
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  6. Steve
    Steve avatar
    124 posts
    Member since:
    Jun 2011

    Posted 12 Jul 2013 Link to this post

    I assume that for validating user input, the best course of action is to handle the CellValidated event and add the ValidationResult to a collection, but if existing data (from a data source) is invalid (exceeds valid string length), how can I get at that ValidationResult?
    Thanks in advance,
    Steve
  7. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 17 Jul 2013 Link to this post

    Hello Steve,

    Will it be possible to clarify how you get this error ? Do you work with DataAnnotation and set Length restriction or you perform check in the property setter for example ?  

    Regards,
    Maya
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  8. Steve
    Steve avatar
    124 posts
    Member since:
    Jun 2011

    Posted 17 Jul 2013 Link to this post

    I use DataAnnotations.
    Thanks,
    Steve
  9. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 18 Jul 2013 Link to this post

    Hello Steve,

    In this case my recommendation is to take a look at one of those articles (link 1, link 2, link 3).  

    Regards,
    Maya
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
Back to Top
UI for WPF is Visual Studio 2017 Ready