+ Reply to Thread
Results 1 to 3 of 3

Use a NAME in a NAME?

  1. #1
    Registered User
    Join Date
    11-23-2011
    Location
    CO
    MS-Off Ver
    Excel 2007
    Posts
    4

    Use a NAME in a NAME?

    I have 7 columns of data I enter daily into Excel. That data is automatically graphed. However, I must set the range of the data in order to properly graph it. So each day, I must use the Name Manager to change the range of the data to reflect the new data just added. Is there another way to do that rather than changing each variable's range to the new row the data resides in. I'd envision something like this:

    Name: current_end_of_range ----- Refers to: =$F$4642
    Name: DateRange ----- Refers to: =Sheet1!$F10$:current_end_of_range

    OR, more ideally:

    Name: current_row ----- Refers to: =4642
    Name: DateRange ----- Refers to: =Sheet1!$F10$:$F$current_row

    but, of course, I cannot do it either of those ways. Is there a way that works?

    Thanks for your help!

    Doug

  2. #2
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Use a NAME in a NAME?

    Hi dbasmb and welcome to the forum,

    Excel has thought of this problem and the topic is Dynamic Named Ranges.
    Read:
    http://www.ozgrid.com/Excel/DynamicRanges.htm or
    http://www.beyondtechnology.com/geeks007.shtml or
    http://www.contextures.com/xlNames01.html
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  3. #3
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Use a NAME in a NAME?

    Hello,

    if you already have the addresses established in the range names, then you can use Index to pinpoint the range.

    Name: current_end_of_range ----- Refers to: =$F$4642
    Name: DateRange ----- Refers to: =Sheet1!$F10$:current_end_of_range
    I assume you mean =Sheet1!$F$10 instead of =Sheet1!$F10$, and assuming that current_end_of_range is on Sheet1, you can reference the range in a formula, for example Sum() like this:

    =sum(Sheet1!$F10$:current_end_of_range)

    or if you want to use only the row number:

    Please Login or Register  to view this content.
    =sum(Sheet1!$F10$:index(Sheet1!$F:$F,current_row))

    Of course you can also use named ranges in the definition of other named ranges. Actually, that's one of their major uses.

    MyRange refers to =Sheet1!$F10$:index(Sheet1!$F:$F,current_row)



    cheers,
    Last edited by teylyn; 11-23-2011 at 03:28 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1