Don't want cell references to update to another worksheet.

%3CLINGO-SUB%20id%3D%22lingo-sub-1947081%22%20slang%3D%22en-US%22%3EDon't%20want%20cell%20references%20to%20update%20to%20another%20worksheet.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1947081%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%26nbsp%3B%20I%20have%20worksheet%20B%20that%20copies%20cell%20data%20from%20worksheet%20A.%26nbsp%3B%20Every%20time%20I%20insert%20a%20row%20in%20sheet%20A%2C%20sheet%20B%20is%20updated%20and%20then%20the%20data%20from%20the%20newly%20inserted%20row%20in%20sheet%20A%20doesn't%20show%20up%20in%20sheet%20B.%26nbsp%3B%20How%20can%20I%20make%20some%20sort%20of%20an%20absolute%20cell%20reference%20in%20sheet%20B%20that%20won't%20update%20when%20the%20row%20is%20inserted%20in%20sheet%20A%3F%26nbsp%3B%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1947081%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1947454%22%20slang%3D%22en-US%22%3ERe%3A%20Don't%20want%20cell%20references%20to%20update%20to%20another%20worksheet.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1947454%22%20slang%3D%22en-US%22%3E%3CP%3EHi%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F887955%22%20target%3D%22_blank%22%3E%40Mrmusick%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Ecan%20you%20please%20attach%20sample%20file%3F%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ERegards%2C%20Faraz%20Shaikh%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1950975%22%20slang%3D%22en-US%22%3ERe%3A%20Don't%20want%20cell%20references%20to%20update%20to%20another%20worksheet.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1950975%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F156456%22%20target%3D%22_blank%22%3E%40Faraz%20Shaikh%3C%2FA%3E%26nbsp%3BThanks%20for%20looking%20into%20this.%26nbsp%3B%20%26nbsp%3BI%20attached%20the%20sheet.%26nbsp%3B%20Maybe%20another%20way%20of%20looking%20at%20it%20is%20to%20insert%20a%20row%20in%20the%20'contact%20history'%20sheet%20whenever%20I%20add%20a%20new%20contact%20in%20'person%20data'.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20problem%20is%20that%20when%20I%20add%20a%20new%20person%20(row)%20in%20'person%20data'%20%2C%20I%20need%20to%20manually%20insert%20a%20row%20and%20update%20the%20'contact%20history'%20sheet%20to%20include%20that%20person.%26nbsp%3B%20%26nbsp%3BHow%20can%20I%20make%20this%20happen%20automatically%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%20for%20your%20help.%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

Hi,  I have worksheet B that copies cell data from worksheet A.  Every time I insert a row in sheet A, sheet B is updated and then the data from the newly inserted row in sheet A doesn't show up in sheet B.  How can I make some sort of an absolute cell reference in sheet B that won't update when the row is inserted in sheet A?  

 

Thanks.

5 Replies

Hi @Mrmusick 

 

can you please attach sample file? 

 

Regards, Faraz Shaikh

@Faraz Shaikh Thanks for looking into this.   I attached the sheet.  Maybe another way of looking at it is to insert a row in the 'contact history' sheet whenever I add a new contact in 'person data'. 

 

The problem is that when I add a new person (row) in 'person data' , I need to manually insert a row and update the 'contact history' sheet to include that person.   How can I make this happen automatically?

 

Thanks for your help.

In contact history, cell A2, try:

=INDEX('Person Data'!$F$2:$F$68,ROWS(A$2:A2))

Then, copy/paste special - formula down your column.

@JMB17 Thanks.    That works for the cells where data is being directly copied over.   

 

But somehow I would like to insert the row all across the 'contact history' sheet.    Is it possible to insert a row on the second sheet when a row is inserted on the first sheet?

 

Thanks alot.

@Mrmusick 

 

I see what you mean. The remaining fields are inputs and won't match the correct family.

 

For a formula solution, you would probably need to set up a column on the contact log for the family ID. The user could input the family ID and then you could use a vlookup formula to pull in the adult/children names from your names table.

 

Otherwise, it will require vba. I would name the table containing the family names as well as the adult and children columns so vba can easily find those ranges. Also, I added a gray border at the bottom as a visual cue that all rows must be inserted at or above that border row. When the workbook opens, it would need to capture the number of rows of the table. Then, set up a worksheet change event handler to compare the current row count to the saved row count and determine if rows were inserted. Then, insert rows at the same location in the contact worksheet and link the adult/children cells back to the name table.

 

If it were me, I would first look to use ID numbers and lookup formulas. But, I attached a file using vba to insert the rows if you want to look at it. If the user selects a non-contiguous area when inserting rows, then it's not as straightforward to insert the rows in the contact worksheet because excel apparently starts at the bottom and passes one area at a time (so, there is a row offset calculation to handle that situation).