How to constrain users from selecting a ScheduledEndDate that is before the ScheduledStartDate on Change

Version 1

    Details

    You may want to prevent your end users from selecting an  end date that is less than the start date when creating a Change record. The steps below outline how to configure a validation rule that will not allow a save unless the EndDate is greater than the StartDate. 


    Resolution

     

    To Restrict Users from entering an ScheduledEndDate that is less than the ScheduledStartDate, configure a validation rule on the Change Business Object. 

    To do this:

    Go to Change Business Object
    Go to Business Rules
    Go to Regular Expression Validation Rules
    Add new rule
    Select the ScheduledEndDate field
    Expression type = Custom
    Expression:   

    $(ScheduledEndDate > ScheduledStartDate

    Error Message: The ScheduledEndDate must be greater than the ScheduledStartDate

    Name the rule.
    Save.





    This validation rule will not allow the user to save if the EndDate is before the StartDate


    Upon save, user will be presented with the error message and will be unable to save until they change the EndDate to be after the StartDate: