Static formula when inserting new rows/columns?

N

nfe

I have a sheet that i want to make a macro for. However i dont want the
formulas to update to the new cell references when i insert new
columns/rows. Ive tried locking the cells but the it still updates.

The other idea ive had is just add the formula editing to the macro.
However this is a bit long winded.

Thanks in advance
 
B

Bernie Deitrick

Use the INDIRECT function:

=INDIRECT("A1")

will always return the current A1 cell's value, no matter what happens with row insertion/deletions.

HTH,
Bernie
MS Excel MVP
 
N

nfe

Apologies it doesnt seem to do all i require of it, or i dont have the
grasp of it ..

I want to write something like, =Indirect("(i4/j4-1)*100)") but it
doesnt seem to like this syntax?

Thanks
 
P

Pete_UK

You can only have a cell reference in the INDIRECT( ) function. I think
what you are trying to do is this:

=(INDIRECT("I4")/INDIRECT("J4") -1)*100

Hope this helps.

Pete
 
Top