+ Reply to Thread
Results 1 to 6 of 6

How to fix reference cells so that not affected by changes to the reference

  1. #1
    Registered User
    Join Date
    04-11-2015
    Location
    Singapore
    MS-Off Ver
    2010
    Posts
    54

    How to fix reference cells so that not affected by changes to the reference

    I have the below formula in a column that refer to another worksheet:
    e.g.
    ...
    =IF('NameList'!J40="","",'NameList'!J40)
    =IF('NameList'!J41="","",'NameList'!J41)
    =IF('NameList'!J42="","",'NameList'!J42)
    =IF('NameList'!J43="","",'NameList'!J43)
    ...

    But when I do update/changes to the list, e.g. insert row 41, my table will become
    ...
    =IF('NameList'!J40="","",'NameList'!J40)
    =IF('NameList'!J42="","",'NameList'!J42)
    =IF('NameList'!J43="","",'NameList'!J43)
    ...

    and all new data inserted in between existing rows are not able to be captured by the formula.

    May I know what changes or settings do I need to do?

    thank you.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,445

    Re: How to fix reference cells so that not affected by changes to the reference

    I'd suggest you convert your data into a Structured Table. That should maintain the formulae for you.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,728

    Re: How to fix reference cells so that not affected by changes to the reference

    You could avoid inserting rows into your reference data, and add new data to the end of the existing data.

    OR, you could just copy the first of those formulae down after you have inserted or deleted some rows.

    OR, you could change the formula to this:

    =INDEX('NameList'!J:J,ROWS($1:40))&""

    and copy this down.

    OR, you could change the formula to one that uses INDIRECT, but as that is a volatile function you may see performance issues.

    Hope this helps.

    Pete

  4. #4
    Forum Contributor
    Join Date
    11-27-2009
    Location
    Austin, Texas
    MS-Off Ver
    Excel 2013 & 2016
    Posts
    409

    Re: How to fix reference cells so that not affected by changes to the reference

    Ljung,

    TMS is correct, this is your best option. Use a structured table option, within your data, do a ctrl-t to convert your data, and give the data a name. As you add data to the bottom row, it will become part of the structured table.
    Thanks
    ==========
    Bigroo1958
    Austin, Texas
    ==========

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,445

    Re: How to fix reference cells so that not affected by changes to the reference

    As you add data to the bottom row, it will become part of the structured table.
    But, just as important, inserting rows will have the formulae applied without having to copy them.

  6. #6
    Registered User
    Join Date
    04-11-2015
    Location
    Singapore
    MS-Off Ver
    2010
    Posts
    54

    Re: How to fix reference cells so that not affected by changes to the reference

    Pete, thanks for the various options. I would avoid inserting rows in between myself, but I am not sure who else will be using this table. So I am trying my best to make it more flexible
    For the formula, it works, but I have some other cells that is vlookup to this column and apparently they do not work well with each other.

    TMS, Bigroo,
    Thanks for the lead, I am still exploring the structured table option. After some quick try, am I right to say that this structured table only works for formula within the same worksheet?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 1
    Last Post: 08-14-2015, 02:49 AM
  2. Indirect Sheet reference with cell reference left function and text
    By teststrip in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-01-2015, 10:31 AM
  3. [SOLVED] Locked formula changes reference when rows added to reference sheet in same workbook
    By macrorookie in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-19-2014, 04:08 PM
  4. [SOLVED] reference the affected sheet
    By blackspiral in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-21-2013, 04:19 PM
  5. Replies: 0
    Last Post: 11-15-2007, 02:35 AM
  6. Making VLookup Absolute reference and deleting worksheet reference question
    By crowdx42 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-24-2006, 12:45 PM

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