check vacation request on other form
Hi all,
Could anyone help me what's wrong with this code?
My intention is if the assistant set vacation status on the Timesheet form the script should check if the employee has a valid vacation request for the certain day on Vacation form.
checkvacreq=Vacation[ID==input.Name];
if(checkvacreq.count>0)
{
if(Date >= checkvacreq.Start && Date <= checkvacreq.End)
{
alert " Employee has a vacation request for today";
}
else
{
alert " Employee does not have a vacation request for today";
}
}
Thanks a lot!
George