Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Dynamic Cell Range

I've been trying to figure out how to get dynamic range selections.

I have a list of numbers in one column and in the adjecent column I
want it to give me the largest number in the previous n rows, where n
is a number in another cell. anyone know how this is or can be done?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Dynamic Cell Range

As a worksheet formula?

I put n in A1.

I put my numeric data in D1:D30
In E30, I put this formula:
=MAX(OFFSET(D30,-A1,0,A1,1))
It evaluated the same way as:
=max(d20:d29)

If I wanted the equivalent of:
=max(d21:d30)
Then I'd use a formula like:
=MAX(OFFSET(D30,-A1+1,0,A1,1))







wrote:

I've been trying to figure out how to get dynamic range selections.

I have a list of numbers in one column and in the adjecent column I
want it to give me the largest number in the previous n rows, where n
is a number in another cell. anyone know how this is or can be done?


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default Dynamic Cell Range

Thanks, I got what I want
Cell C5=MAX(B5:OFFSET(Sheet1!B5,0,0,Sheet1!$E$1,1))

Where my colum of data starts in B5 and n is in cell E1. When I
drag/copy into the rest of the cells in column C it updates the B5 to
B6, B7, etc.

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
Dynamic Range Defined by Value of Cell Domenick Excel Worksheet Functions 7 December 18th 09 01:53 PM
Dynamic range where the reference cell can change hello Excel Discussion (Misc queries) 2 May 19th 08 10:11 PM
Dynamic cell range for functions Rob Hayles Excel Worksheet Functions 1 August 16th 06 10:32 AM
copying dynamic range based on cell outside of range xcelelder Excel Programming 3 September 29th 05 05:08 PM
Cell Data Validation with dynamic Range Arishy[_2_] Excel Programming 1 August 18th 05 08:49 AM


All times are GMT +1. The time now is 10:50 PM.

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"