Thread: IF Formula
View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.misc
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default IF Formula

=SUM(A2:OFFSET(A2,0,MATCH(k2,1:1,0)-1))


--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Don Guillett" wrote in message
...
=SUM(A5:OFFSET(A2,0,MATCH(k2,1:1,0)-1))

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Lisa" wrote in message
...
I need help with the formula.

A B C D E
1 Jan Feb Mar Apr May
2 10 5 15 7 8

If K2 is Mar I need to sum A2 thru C2. If K2 is May I need to sum A2 thru
E2.

Thank you in advance.