Questions tagged [validation]

For questions related to Sitecore item and field validation rules within the Sitecore Client

Filter by
Sorted by
Tagged with
9
votes
3answers
1k views

Item validator access already stored data instead of newly inputed data

Im facing a problem with sitecore item validator when I try to save the data. The purpose of my validator (the class inherit from StandardValidator) is to simply check if, atleast, field A or field B ...
3
votes
2answers
2k views

Make one of two sitecore content fields required?

I've been trying to find a way to make one of two fields valid and haven't come up with much. Is there a way to do this with custom field validators or is that just relevant to individual fields? ...
7
votes
1answer
641 views

Standard Required field validation reporting field is empty after upgrade to Sitecore 9.0 Update-2

We're getting an interesting validation error after upgrading from Sitecore 8.2 Update-6 to Sitecore 9 Update-2. We have the standard Required validator on a field (item name of the field is Title). ...
2
votes
1answer
2k views

Sitecore Field Validator Change to Custom Message

I have a field that is a required field validator in Sitecore. I marked that field as required and Set the parameter=FatalError so that users cannot save the item without entering data in that field. ...
1
vote
0answers
439 views

FatalError Required validation not working

I am using SXA 1.8, and Sitecore 9.1 I am trying to add a validation for a Date type field where it is required, and the user cannot save the item unless this field has a value, I have copied ...
2
votes
2answers
2k views

'IServiceProvider' does not contain a definition for 'GetService'

This is the first time i deal with custom validations, but I need to create a unique email validation using sitecore 9.0.2 and SXA 1.7.1 so i was following this tutorial http://sitecoresolution....
7
votes
2answers
578 views

How do i validate an image for byte-size in Content Editor?

I would like to Validate the Image Field say i shouldn't allow the image more than 1 MB. How do I do that in content editor?
4
votes
1answer
1k views

Sitecore validation rule at field level in multi-list value selection range

I came across this multi-list field restrictions to limit range(selection) using regex. I got few references to add basic validations. Both work fine. Ref1: ^({[^}]+}\|?){0,5}$ http://www.benramey....
4
votes
0answers
337 views

Apply field validations across fields

I'm building a component that, among other fields, contains "title" and "text" fields. The business logic is: If both fields are empty, that is OK If both fields are populated, that is OK If one ...