AI OnAI Off
In stead of
[Range(1,5, ErrorMessageResourceName = "/contenttypes/icontentdata/errormessages/invalidamountnews")]
use
[Range(1,5, ErrorMessage = "/contenttypes/icontentdata/errormessages/invalidamountnews")]
However this will still not display your error message all the time.
If you enter an invalid value like "abc" you will see your error message.
If you enter a valid integer that is out of range you will see the default error message.
I haven't found a solution for this other than writing my own validator.
/Mark
Hello!
How should the path to the resource string containing error messages should be passed to Range attribute in int properties?
I have declared the property like this:
And then in language file:
This is not working and the property view for the pages of the page type loads forever, so I guess I'm passing the wrong path to the attribute. Can't find any good example either.
Does anybody have any suggestions?
/Kenia