Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Adjust Planned Start date and End Date in the Change Form.

Jayakrishna3
Tera Contributor

I had one requirement like if planned date and end date is either one of black out schedule time then I need to show section tab in change form.

7 REPLIES 7

Ankur Bawiskar
Tera Patron
Tera Patron

@Jayakrishna3 

are you saying if start and end falls between the blackout then show section or else hide it?

you can use onLoad client script and validate that and use g_form.setSectionDisplay('sectionName', false) to hide it.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

Thanks for Reply, I had added the detailed description along with Code. 

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @Jayakrishna3 

For this, you need to run a loop on the blackout schedule table and check if the change dates fall within the BW dates. I checked in PDI, and there is no related list available in the BW schedule that indicates which changes are occurring within the BW window. You can use the out-of-the-box conflict script and, based on that, make the necessary changes. It's not as simple as it seems.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Thanks for Reply, I had added the detailed description along with Code.