View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Barb Reinhardt Barb Reinhardt is offline
external usenet poster
 
Posts: 3,355
Default how to set last/latest value of a line chart to a static cell?

You could use the OFFSET function to get there. Without knowing what else
you have on your sheet, it's tough to tell you what to do.

Let's assume this
1) Your data is in row 2
2) A2: Identifier for the data
3) B2: ...end of data is numeric data that's entered

Set a named range to this
=OFFSET(Sheet1!$A$2,0,count($2:$2)

Once you have that named range working, you can refer to the named range.
As you add data, you the "current data" moves to the right.

HTH,
Barb Reinhardt

"Rich" wrote:

Each day I have to add a value to the NEXT cell in a column on a worsheet
which is the datasource for an Excel line chart. I want to display the
last/latest value entered in this range to a static cell in the worksheet
(which I will be referencing elsewhere). Since the latest value entered in
this range is in a different cell each day (the next cell in the range) how
can I capture this latest value - the way the line chart does? Is there a
worksheet formula/set of formulas that could accomplish this? One solution
I am thinking of is to write a VBA function that checks for the latest value
entered in this range and then set the value of this VBA function to my
static cell. Can I do this with worksheet formulas? Or should I go with the
VBA function idea?

Thanks,
Rich