Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Carl Sjöholm 23 posts 194 karma points
    Mar 20, 2019 @ 19:40
    Carl Sjöholm
    0

    Dictionary and Unobtrusive validation

    Normally I would use a .resx file for unobtrusive valdation.

    [Required(ErrorMessageResourceType = typeof(Resource), ErrorMessageResourceName = "Required"]
    

    Is there anyway to use umbraco dictionary instead?

  • Mila Pandurska 75 posts 350 karma points
    Oct 16, 2019 @ 07:36
    Mila Pandurska
    0

    Hi Carl,

    Did you find a way to achieve this requirement with Umbraco 8 Dictionaries?

    Mila

  • Carl Sjöholm 23 posts 194 karma points
    Oct 16, 2019 @ 07:48
    Carl Sjöholm
    0

    Hi Mila,

    This would mean that I have to write my own validators that inherit from the already existing within .net.

    E.g.

    public class DisplayImpl : Display {
         public override string Name { ... }
    }
    

    Or something similar. If you have a better solution please share it.

    // C

  • Mila Pandurska 75 posts 350 karma points
    Oct 16, 2019 @ 10:16
    Mila Pandurska
    0

    Hi Carl,

    I am trying to do the same - create my own validators, but currenty I have no success. If you achieve this can you share some code.

    Thank you

  • Markus Johansson 1696 posts 4865 karma points c-trib
    Oct 16, 2019 @ 11:40
    Markus Johansson
    0

    Hi!

    Have you had a look at this package?

    https://our.umbraco.com/packages/developer-tools/validation-attributes-for-custom-forms/

    I'm not using it my self since I've already implemented something similar before this was released but it looks promising.

  • Mila Pandurska 75 posts 350 karma points
    Oct 16, 2019 @ 12:53
    Mila Pandurska
    0

    Hi Marcus,

    I am looking for Umbraco 8 solution. Do you think that this package will work on Umbraco 8?

Please Sign in or register to post replies

Write your reply to:

Draft