Q10740 - INFO: NDM

NDM returns the Number of Days in a Month or the number of specified weekdays in a month.

SYNTAX:

NDM(MonthOffset/Date, optional Weekdays)

MonthOffset/Date: If a number it is the Zero based offset from the Start Date of the report. If this field is a date string (i.e. "07/16/2004") or refers to a cell with a date in it, it sets the month to calculate for

Common values:

0 = Current month
1 = One month after current month
2 = Two months after current month

Weekdays: Optional parameter.  If omitted function returns the total number of days in the month.  Is a string that specifies which days of the week to count.  You can combine strings to count more than one weekdays.  "MW" counts Mondays and Wednesdays in the month.

Su - Sunday
M - Monday
Tu - Tuesday
W - Wednesday
Th - Thursday
F - Friday
Sa - Saturday

EXAMPLES:

Start Date of Report is 12/01/2014

 Formula Returns Explanation NDM(0) 31 Current month is December 2014 which has 31 days. NDM(1,"M") 4 One (1) month after start month of report is Jan 2015 which has 4 Mondays. NDM("1/1/2001") 31 Janurary 2001 has 31 days. NDM(B5) 28 B5 displays 2/1/2015 (Feb 1st 2015) which has 28 days.

See Also: GNOS to count the number of samples and GSV to test for missed samples.

 Related Articles No Related Articles Available.

 Article Attachments No Attachments Available.