Posted: 17 Mar 2016 12:29 EDT Last activity: 29 Mar 2016 12:51 EDT
Has anyone used TimeDifferenceFirstBusinessDay() Function ?
Have anyone used TimeDifferenceFirstBusinessDay() Function? I am having trouble with the aCalendar parameter.
It says that if aCalendar is null - it should use server's default calendar and local time zone, but it is failing validation if I leave it null.
And what should one give for the calendarObject? should I have to provide the instances of Data-Admin-Calendar ?
Description: Returns the first business day after the specified DateTime, using the specified calendar. Usage: Returns the first business day after the specified date, using "business day" logic (assumes US business day rules (Saturday/Sunday closed), ignores possibility of holidays (constant 5 day weeks)). Parameter: aCalendar: calendar to be used for computation, if null, uses the server's default calendar and local time zone strStart: base date/time, if null or zero length, uses the current date and time
You can't directly call this function by passing the Calendar event in the Property-Set of an activity. but you can call it from java code like below. This was one of the oldest functions created by Pega, I guess.
1) Create a local parameter:nextBizDay from a test activity.
2) Use the below java code in that activity and write the below code to set the local param.