Date restriction - earliest 7 working days from now, latest 3 month from today

Guna Shalini M
Tera Expert

I have a date field in a catalog item. It should be restricted within earliest 7 working days from now, latest 3 month from today. Please help on how to implement this @Ankur Bawiskar 

Thanks!

1 ACCEPTED SOLUTION

Guna Shalini M
Tera Expert

I completed it with UI policy

Date relative before 7 days from now or relative after 3 months from now -> Error message will be displayed using Run Script

View solution in original post

8 REPLIES 8

Does this code skip saturdays and sundays?

No,

For that, you need to include cmn_schedule in the script include.

 

Please mark my answer as helpful/correct if it resolves your query.

 

Regards,

Gunjan Kiratkar

Consultant - ServiceNow, Cloudaction

Rising Star 2022

 

 

 


Please Mark My Response as Correct/Helpful based on Impact
Regards,
Gunjan Kiratkar
2X ServiceNow MVP
Community Rising Star 2022
Youtube : ServiceNow Guy

Thank you all for your efforts. But I found a solution using UI policies and it worked.

Guna Shalini M
Tera Expert

I completed it with UI policy

Date relative before 7 days from now or relative after 3 months from now -> Error message will be displayed using Run Script