Results 1 to 16 of 16

Getting value from next-highest 'header' row

Threaded View

  1. #1
    Registered User
    Join Date
    01-28-2009
    Location
    North Carolina, USA
    MS-Off Ver
    Excel 2000
    Posts
    12

    Getting value from next-highest 'header' row

    Hi all,

    I have a worksheet that contains a number of rows. [Thank you, Captain Obvious!] These rows are logically grouped to represent a series of "items", with each item having one or more rows (with a "header" row at the top). The rows for a particular item represent different types of information about that item, and therefore make use of different formulas based on the row type. Due to the relative complexity of the formulas in these rows, I am creating a series of row "templates" from which I can copy and paste every time I want to create a new item or add rows to an item. As such, I am trying to avoid direct cell references to different rows, as these would easily get messed up during cut and paste. Instead, I am trying to limit myself to various lookup functions (e.g. OFFSET, MATCH, etc...) that will work regardless of where a row is added.

    In order to accomplish this I am using a "key" column to group all rows for a particular item together. Until now I have had to type in the key value for every row for a particular item. What I would like to do is to only have to type the key value in the header row, and have a formula populate the key value in all subsequent rows ... until a new header row is reached, at which point the new key value will be used. Take a look at the following example:

    a) Item Header row containing key value in column A and a header "flag" in column B
    b) Item Detail row containing key lookup formula in column A
    b) Item Detail row containing key lookup formula in column A
    b) Item Detail row containing key lookup formula in column A
    > Blank separator row
    b) Item Detail row containing key lookup formula in column A
    b) Item Detail row containing key lookup formula in column A
    > Blank separator row
    b) Item Detail row containing key lookup formula in column A
    b) Item Detail row containing key lookup formula in column A
    > Blank separator row
    c) Item Header row containing key value in column A and a header "flag" in column B
    d) Item Detail row containing key lookup formula in column A
    d) Item Detail row containing key lookup formula in column A
    > Blank separator row
    d) Item Detail row containing key lookup formula in column A
    > Blank separator row
    e) Item Header row containing key value in column A and a header "flag" in column B
    f) Item Detail row containing key lookup formula in column A
    f) Item Detail row containing key lookup formula in column A

    In the above:

    - column A in all "b" rows should lookup the key value in column A of row "a".
    - column A in all "d" rows should lookup the key value in column A of row "c".
    - column A in all "f" rows should lookup the key value in column A of row "e".

    Can anyone suggest how I can accomplish this? I don't want to use direct references between rows. I would like some formula that will fetch the value from column A in the first row above the current row that contains the "flag" in column B.

    I appreciate any help you can offer!

    Thanks,
    Greg
    Last edited by gurtz; 01-30-2009 at 08:13 AM.

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