#1   Report Post  
Blue Hornet
 
Posts: n/a
Default

Okay, this doesn't seem too difficult.

Your A1 date is "any start date" and your B1 date is "any subsequent
Friday", correct? And you want to know how many full weeks and partial
weeks (counted as full) occur between A1 and B1.

Then the formula in C1 should be:
=CEILING( DATEDIF( A1, B1, "d") / 7, 1)

This will:
Determine the days between A1 and B1 (DATEDIF),
Divide that by 7 (to get "weeks" and "partial weeks" as a decimal),
Round that upward (if necessary) to the nearest whole number (CEILING).

Chris

  #2   Report Post  
Ron Rosenfeld
 
Posts: n/a
Default

On 18 Aug 2005 17:30:54 -0700, "Blue Hornet" wrote:

Okay, this doesn't seem too difficult.

Your A1 date is "any start date" and your B1 date is "any subsequent
Friday", correct? And you want to know how many full weeks and partial
weeks (counted as full) occur between A1 and B1.

Then the formula in C1 should be:
=CEILING( DATEDIF( A1, B1, "d") / 7, 1)

This will:
Determine the days between A1 and B1 (DATEDIF),
Divide that by 7 (to get "weeks" and "partial weeks" as a decimal),
Round that upward (if necessary) to the nearest whole number (CEILING).

Chris


One question that occurs to me is how to handle the situation where two partial
weeks are rented. For example, if someone starts renting on Friday 5 Aug 2005
and stops on Monday 8 Aug 2005, does that count as one week? or two weeks?


--ron
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Calculate weeks cover \Kevin Carroll via OfficeKB.com\ Excel Worksheet Functions 2 July 8th 05 01:00 AM
Counting names in a column but counting duplicate names once TBoe Excel Discussion (Misc queries) 9 May 11th 05 11:24 PM
Counting... Patrick G Excel Worksheet Functions 3 February 23rd 05 10:05 PM
calculate weeks from a start date ( not yr weeks) Todd F. Excel Worksheet Functions 6 November 27th 04 05:53 PM
Weekly data into Calendar Weeks ExcelMonkey Excel Worksheet Functions 2 November 22nd 04 08:41 PM


All times are GMT +1. The time now is 07:02 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"