+ Reply to Thread
Results 1 to 2 of 2

Changing start point in Dynamic Named Ranges for a Chart

  1. #1
    Forum Contributor
    Join Date
    08-14-2006
    Location
    USA
    MS-Off Ver
    2019
    Posts
    686

    Changing start point in Dynamic Named Ranges for a Chart

    I have created Dynamic Named Ranges for a Chart

    Source Data > Data Range

    ChrtRng
    =OFFSET(Sheet2!$A$1,0,0,COUNTA(Sheet2!$A:$A),3)
    Current result = A1:C154


    Source Data > Series > Values

    ChrtRngBooked
    =OFFSET(Sheet2!$B$1,0,0,COUNTA(Sheet2!$A:$A),1)
    Current result = B1:B154

    ChrtRngShifted
    =OFFSET(Sheet2!$C$1,0,0,COUNTA(Sheet2!$A:$A),1)
    Current result = C1:C154


    Source Data > Series > Category X axis Labels

    ChrtRngMoYr
    =OFFSET(Sheet2!$A$1,0,0,COUNTA(Sheet2!$A:$A),1)
    Current result = A1:A154

    Everything works fine to this point. Adding or deleting rows changes the chart.
    The chart contains monthly data for 1997 thru the present.



    Now I would like another chart that doesn't start at Row 1
    it starts at whatever cell is Jan of the Year the user selects.

    StartYr = ChrtSht!B2
    here the user enters the year they want the chart data to start
    Current result = 2003

    =MATCH(DATE(StartYr,1,1),ChrtRngMoYr)
    Current result = 74 (Sheet2!A74 = 1/1/2003)

    I cannot figure out how to plug 74 into my Dynamic Named Range formulas in place of the 1
    (Sheet2!$A$74 instead of Sheet2!$A$1)

  2. #2
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,437

    Re: Changing start point in Dynamic Named Ranges for a Chart

    The new information would replace one of the zeros, which define the amount to offset from anchor cell

    =OFFSET(Sheet2!$A$1,Sheet2!$A$74,0,COUNTA(Sheet2!$A:$A)-Sheet2!$A$74,3)

    may requrie a +1 on the counta part of the formula.
    Cheers
    Andy
    www.andypope.info

+ 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