+ Reply to Thread
Results 1 to 8 of 8

formulas with dynamic references to cells

  1. #1
    Registered User
    Join Date
    02-02-2009
    Location
    hhhh
    MS-Off Ver
    Excel 2003
    Posts
    39

    formulas with dynamic references to cells

    Hello all,

    Below is my problem. My spreadsheet contains two sheets. One sheet has 3 columns with "name" "number" and "product" in columns A,B,C respectively. Sheet2 contains "name" and "amount in" columns A,B respectively. I have formula in sheet1 of column c to multiply the value in sheet1!B with Sheet2!B. The problem is the column amount in sheet2 dosn't always have to be in column B. next time the data is refreshed it can be in column C. The only common thing will be that column "name" and "amount" will be next to each other and the column names will always stay the same. How can i acheive this using excel formulas. Macros will be my last option. I have attached a sample spreadsheet.

    Any help is greatly appreciated.
    Attached Files Attached Files

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: formulas with dynamic references to cells

    Are the headers always in the same row on Sheet2 ?

  3. #3
    Registered User
    Join Date
    02-02-2009
    Location
    hhhh
    MS-Off Ver
    Excel 2003
    Posts
    39

    Re: formulas with dynamic references to cells

    yes, the headers will always remain the same.

  4. #4
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: formulas with dynamic references to cells

    so in what row will they appear ?

  5. #5
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: formulas with dynamic references to cells

    If we assume headers always appear in row 2

    Please Login or Register  to view this content.
    Then assuming you're not deleting columns etc on Sheet2 you could use:

    Please Login or Register  to view this content.
    Not very elegant but it should work... alter ranges as required.

  6. #6
    Registered User
    Join Date
    02-02-2009
    Location
    hhhh
    MS-Off Ver
    Excel 2003
    Posts
    39

    Re: formulas with dynamic references to cells

    sorry,

    i misunderstood your question. The header "name" will always be the same in both sheets.

  7. #7
    Registered User
    Join Date
    02-02-2009
    Location
    hhhh
    MS-Off Ver
    Excel 2003
    Posts
    39

    Re: formulas with dynamic references to cells

    if you don't mind can you please post an example sheet?, the row header will always remain the same, only the column order changes.

  8. #8
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: formulas with dynamic references to cells

    Just insert the formulas provided into your sample file as advised.

    If you change the headers in row 2 on Sheet2 you should find the values on Sheet1 update accordingly.

+ 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