+ Reply to Thread
Results 1 to 9 of 9

Named range formula

  1. #1
    Registered User
    Join Date
    08-15-2011
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    7

    Named range formula

    Hi guys,

    I've been trying to sort out defined names for hours with little luck.

    I have several columns filled with IF statements, pulling numeric values where they exist and returning the word "FALSE" where no data exists. There is a header row, and 99 rows of results in each column.

    I want to make defined ranges I can then use in charts (SERIES formula) which select just the numeric values in each column (ie not the cells that return "FALSE"). I currently have the formula, =OFFSET('Middle Is'!$G$2,0,0,COUNT('Middle Is'!$G$1:$G$100),1)

    This formula works when G2 is numeric, but not when it returns "FALSE" even though there are numeric results further down the column.

    I'd be most appreciative of any help. Do I need a different formula? I'm stuck!

    Cheers
    Last edited by global_zoo; 08-16-2011 at 07:29 AM.

  2. #2
    Registered User
    Join Date
    08-15-2011
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    7

    Re: Named range formula

    PS I'm using Excel 2007

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

    Re: Named range formula

    Hi global_zoo and welcome to the forum,

    It looks like you are trying to do a Dynamic Named Range. See if http://www.ozgrid.com/Excel/DynamicRanges.htm doesn't help.
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  4. #4
    Registered User
    Join Date
    08-15-2011
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    7

    Re: Named range formula

    Thanks MarvinP.

    I had been looking at the Ozgrid site... it gives the basic formula I'm using [=OFFSET($A$1,0,0,COUNT($A:$A),1)] but it doesn't work. I'm guessing it senses my IF statement as numeric, however, I pasted values and changed the FALSE cells to text with no result.

    Can you include a statement within the formula to specifically tell it to exclude cells with "FALSE"?

  5. #5
    Registered User
    Join Date
    08-15-2011
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    7

    Re: Named range formula

    I've worked out that it is something to do with the reference cell experession in the OFFSET formula. I think I need to change this reference to a nested reference that gives the cell that is the first numeric value in the column. Can INDEX do this?

  6. #6
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Named range formula

    You have a worksheet demonstrating the range you're trying to analyze and a mockup of the results you're trying to achieve?
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  7. #7
    Registered User
    Join Date
    08-15-2011
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    7

    Re: Named range formula

    Quote Originally Posted by JBeaucaire View Post
    You have a worksheet demonstrating the range you're trying to analyze and a mockup of the results you're trying to achieve?
    I sure do, as attached.

    In the file, you'll find the the named ranges I'm working on (ie _0Long, _0Lat, _1Long etc) which use the formula, =OFFSET(S_0Lat,0,0,COUNT('Middle Is'!$G$1:$G$100),1)

    I believe I need to insert some statement to replaced the relative position of the range, currently defined manually by another range (S_0Lat, S_0Long etc).

    Many thanks
    Attached Files Attached Files

  8. #8
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Named range formula

    I don't see why Sheet1 is needed.

    With Sheet2
    In A2
    Please Login or Register  to view this content.
    Drag/Fill Down

    In F2
    Please Login or Register  to view this content.
    Drag Across to Column U then down as required.

    For the Dynamic Names
    e.g. "_0Lat"
    Refers to:=
    Please Login or Register  to view this content.
    Where 0 (red) is the "Bin Class" to be matched and counted.

    Is this what you require?
    Attached Files Attached Files
    Last edited by Marcol; 08-16-2011 at 02:30 PM. Reason: typos
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  9. #9
    Registered User
    Join Date
    08-15-2011
    Location
    Australia
    MS-Off Ver
    Excel 2003
    Posts
    7

    Re: Named range formula

    Marcol - thank you! This is perfect!

    Thanks for taking the time to help me out.

    Cheers

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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