This is a function that takes a start date and end date as parameters and returns the number of weekdays (Monday to Friday) in between. This function assumes that Sunday is set as the first day of the week. Adapted from a vb function that I wrote to calculate standard salary costs for billing purposes.
This version corrects a rounding error that may occur if a time is included with the parameters passed in.
2002-03-27
2,843 reads