WeekDaysInMonth Function
Returns the number of the Week Days (Mon through Fri) in the Given Month/Year.

Unit
QESBPCSDateTime

Declaration
Function WeekDaysInMonth(const Month, Year: Word): Integer;

Description
Exception results for invalid Month.

Parameters
Month Desired Month in the range 1 through 12
Year Desired Year

Category
Date/Time Arithmetic Routines

Implementation

function WeekDaysInMonth (const Month, Year: Word): Integer;
begin
     Result := DaysInMonth (Month, Year) - (DOWsInMonth (1, Month, Year)
          + DOWsInMonth (7, Month, Year))
End;


HTML generated by Time2HELP
http://www.time2help.com