Brian Dunning's FileMaker Custom Functions

CountWeekday.cf ( StartDate ; EndDate ; CustomIgnoreList_as_ddmmyyyy )

Counts the number of weekdays between two dates

  Average rating: 4.4 (31 votes) Log in to vote

Jonathan Jeffery   Jonathan Jeffery
igeek
http://www.igeek.co.uk

Share on Facebook Share on Twitter

  Sample input:
CountWeekday.cf ( get(currentdate) ; date( 12; 31 ; 2013 ) ; "01012013¶29032013¶01042013¶06052013¶27052013¶26082013¶25122013¶26122013" )
  Sample output:
68

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

This function returns the number of weekdays between two dates, ignoring the dates specified on the custom list (these can be, for instance, bank holidays or school vacation dates).

For exmple, CountWeekday.cf ( get(currentdate) ; date( 12; 31 ; 2013 ) ; "01012013¶29032013¶01042013¶06052013¶27052013¶26082013¶25122013¶26122013" ) returns the number of weekdays between today and the end of 2013, minus UK bank holidays.

 

Comments

PJ   PJ
Oct 26, 2018
Hi Jonathan. Tried to input this function into FMP12 in custom functions and it wouldn't have it! 7 lines from the bottom would highlight the first forward facing bracket and claim "...was expecting an operator"... Any small changes you know of that might make this work? Many thanks if you do... :-)
 

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Support this website.

This library has been a free commmunity resource for FileMaker users and developers for 20 years. It receives no funding and has no advertisements. If it has helped you out, I'd really appreciate it if you could contribute whatever you think it's worth: