Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am trying to determine how to write a formula that allows me to calculate
YTD earnings but I cannot figure how to get the year-to-date to work. I know how to get the number of weeks from one date to another (for example 8/1/05-4/12/06 = 255 days or 36.43 weeks). My issue is that I want the formula to count only the weeks YTD 1/1/06-4/12/06. I want the formula to know that if my begin date is in a prior year to only look at the current years weeks. Any assistance would be appreciated. I cannot seem to find an easy solution. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() hi! assuming that the start date is in A1 & end date is in B1, enter in C1: =(B1-A1)/7 and format C1 as Number. -via135 Compliance Crazed Wrote: I am trying to determine how to write a formula that allows me t calculate YTD earnings but I cannot figure how to get the year-to-date to work. know how to get the number of weeks from one date to another (for example 8/1/05-4/12/06 = 255 days or 36.43 weeks). My issue is that I want the formula to count only the weeks YTD 1/1/06-4/12/06. I want the formul to know that if my begin date is in a prior year to only look at th current years weeks. Any assistance would be appreciated. I cannot seem to find an eas solution -- via13 ----------------------------------------------------------------------- via135's Profile: http://www.excelforum.com/member.php...fo&userid=2672 View this thread: http://www.excelforum.com/showthread.php?threadid=52744 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
With the same assumptions as via135, in cell C1 : =IF(YEAR(A1)<YEAR(B1),(B1-(DATE(YEAR(B1),1,1)))/7,(B1-A1)/7) HTH Carim |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Calculations formula | Excel Discussion (Misc queries) | |||
Formula for Asset calculations | Excel Worksheet Functions | |||
Multiple Calculations in a Formula | Excel Discussion (Misc queries) | |||
Calculations Using the =IF formula | Excel Worksheet Functions | |||
Countif Formula with 2 calculations | Excel Discussion (Misc queries) |