Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 38
Default formula with in cell reference

A1 =5 B1=3
A2 =65
A3=12
....
....


How can I do this:


I want C1 have formula to do this:

the sum of A1 to A3

but if B1 change to 5 then

C1 = sum(A1:A5)

and when B1 change to 100
C1=sum(a1:A100)


ie. change the reference formula according to B1.

I have tried C1=sum(a1:A(B1))

but it does not work.




  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 97
Default formula with in cell reference

Hi,

Use :
=SUM(A1:OFFSET(A1,B1,0))

HTH
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 38
Default formula with in cell reference

Thanks Carim. You are very helpful.




"Carim" wrote in message
...
Hi,

Use :
=SUM(A1:OFFSET(A1,B1,0))

HTH



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
format a cell with a formula so an empty reference cell shows blan M2 Excel Discussion (Misc queries) 3 November 7th 06 10:42 PM
Using a cell reference within a cell reference in a formula david Excel Worksheet Functions 2 July 1st 06 01:05 PM
How do I leave formula cell blank if 2nd reference cell is empty? Liana S Excel Discussion (Misc queries) 2 October 21st 05 04:38 PM
Cell Formula reference to cell Based On third Cell Content Gabriel Excel Discussion (Misc queries) 1 February 11th 05 06:36 AM
Cell Formula reference to cell Based On third Cell Content Gabriel Excel Discussion (Misc queries) 0 February 11th 05 05:35 AM


All times are GMT +1. The time now is 06:23 AM.

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

About Us

"It's about Microsoft Excel"