fmsavey Posted November 21, 2007 Posted November 21, 2007 I want to be able to calculate how many month end dates there are between any two dates. Example: Between 1/1/2007 and 3/14/2007 there are 2 month end dates. They are 1/31/2007 and 2/28/2007. Can someone help me with seemingly easy problem? Thanks in advance!
Digital Life Posted November 21, 2007 Posted November 21, 2007 Try Brian Dunning's web site: http://www.briandunning.com/cf/680
comment Posted November 21, 2007 Posted November 21, 2007 Try: 12 * Year ( EndDate ) + Month ( EndDate ) - 12 * Year ( StartDate ) - Month ( StartDate ) Note that this includes StartDate but excludes EndDate, so that: Jan 1, 2007 ... Mar 31, 2007 = 2 Jan 31, 2007 ... Feb 1, 2007 = 1
Recommended Posts
This topic is 6272 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now