View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
T. Valko T. Valko is offline
external usenet poster
 
Posts: 15,768
Default Formula for calculating YTD values

With your month name column headers in the range B1:M1

A10 = some month name

=SUM(B2:INDEX(B2:M2,MATCH(A10,B1:M1,0)))

--
Biff
Microsoft Excel MVP


"Suan" wrote in message
...
Hi
I am trying to set up a table that, when you change the date every month
for
a range of values by month it sums up the YTD value.
eg

Jan Feb Mar April May
June
Salaries 10000 12000 18000 18000 20000 20000
Annual Leave 6000 5000 5000 4500 5500 6000

for example , If we are in the month of April, if I enter the date April
the
formula should calculate Jan - April Salaries and annual leave?
And if I change the date to June the formula should calculate value from
Jan
to June.

Hope it makes sense

Thanks
--
SC