- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-31-2016 05:36 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-01-2016 06:52 AM
Soni,
Add alert in your call back function as shown below and let me know what you see.
Here is your onChange client script on Needed By variable:
function onChange(control, oldValue, newValue, isLoading) {
if (isLoading || newValue == '') {
g_form.setDisplay('title', false); // put in the variable name you want to show or hide according needed by date
return;
}
var ga = new GlideAjax('ValidateNeededBy');
ga.addParam('sysparm_name','validateDate');
ga.addParam('sysparm_needed_by',newValue);
ga.getXML(callBack);
function callBack(response) {
var answer = response.responseXML.documentElement.getAttribute("answer");
alert(answer);
if(parseInt(answer)>=27){
g_form.setDisplay('title', false); // put in the variable name you want to show or hide according needed by date
}
else{
g_form.setDisplay('title', true); // put in the variable name you want to show or hide according needed by date
}
}
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-01-2016 07:05 AM
Actually the name of my variable was not correct. Thanks again for all your help!!!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-01-2016 07:12 AM
Soni,
Glad, you got this resolved.
Note: the value 27 is considering 8-5 schedule (9 hours each day 9*3). If you use 24 hour schedule, make sure you update this value according to your schedule.(so instead of 27 it would be 24*3=72)
Thanks,
Abhinay
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-01-2016 07:27 AM
yeah that's correct! thx
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-26-2017 02:59 AM
Hello Abhinav ,
Could you please help me with similar issue ,
Where I need to have a SLA attached if the Incident is created within 5th - 15th working day of each month.
Any lead on this would be of a great help!
Thanks in advance!!