I’m looking for a way to determine the difference between two dates.
A normal SQL DATEDIFF statement won’t cut it because I need to excluded non working Hours and days Namely Weekends and any time between 16:00 – 7:00.
Something similar to the NETWORKDAYS function in excel.
I’m codeing an excel spreadsheet. Using VBA connect to a SQL server to pull data.
Here is a code sample I got off the net and modified it to work with a table of dates I stored in an access table. I’m sure you could change it again to point at a range in a worksheet etc but the basic idea works a treat