SOLVED

Make all cells references in a long formula absolute

%3CLINGO-SUB%20id%3D%22lingo-sub-1022811%22%20slang%3D%22en-US%22%3EMake%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1022811%22%20slang%3D%22en-US%22%3E%3CP%3EHello%20All%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20have%20a%20long%20formula%20with%20many%20different%20cell%20references.%20Is%20there%20a%20way%20to%20make%20all%20the%20different%20cells%20references%20absolute%20in%20one%20shot%20without%20F4%20every%20cell%20reference%20in%20the%20formula%3F%3C%2FP%3E%3CP%3EFor%20example%20i%20want%20all%20G77%20in%20the%20formula%20below%20to%20be%20%24G%2477%3C%2FP%3E%3CP%3E%3DMIN('LC0-1.4D'!G77%2C'LC1-1.2D%20%2B1.6L'!G77%2C'LC2-1.2D%2B1.6L%2CM2M4M6%2CLL%3D0%20'!G77%2C'LC3-1.2D%2B1.6LM1M3M5M7%2CLL%3D0%20'!G77%2C'LC4-1.2D%2B1.6L%20M3M6%2CLL%3D0%20'!G77%2C'LC5-1.2D%2B1.6LM1M4M7%2CLL%3D0%20'!G77%2C'LC6-1.2D%2B1.6L%20M2M5%2CLL%3D0%20'!G77)%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%2C%3C%2FP%3E%3CP%3ESam%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1022811%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1022843%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1022843%22%20slang%3D%22en-US%22%3E%3CP%3EHello%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ETo%20my%20knowledge%2C%20there%20is%20no%20quicker%20way%20than%20simply%20using%20F4%20on%20each%20cell%20reference.%20My%20suggestion%20would%20have%20been%20to%20use%20find%20and%20replace%20(i.e.%20find%20G%20and%20replace%20with%20%24G%24)%20but%20seeing%20as%20though%20your%20formula%20uses%20cell%20references%20beyond%20the%20first%2026%20columns%20(i.e.%20LC1%2C%20LC2%2C%20LL%2C%20etc...)%20this%20would%20complicate%20things.%20Without%20creating%20a%20macro%2C%20I'm%20afraid%20my%20best%20suggestion%20is%20to%20simply%20use%20F4.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESorry%20if%20this%20isn't%20the%20answer%20you%20were%20looking%20for!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1022892%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1022892%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EDefine%20a%20Name%20to%20reference%20the%20cell%20(by%20default%20it%20will%20be%20an%20absolute%20reference)%20then%20use%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSTRONG%3EApply%20Names...%3C%2FSTRONG%3E%3C%2FP%3E%3CP%3Eon%20the%20%3CSTRONG%3EName%20Manager%3C%2FSTRONG%3E%20ribbon%20tab%20to%20replace%20the%20direct%20reference%20by%20the%20Name.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ENot%20that%20I%20have%20much%20experience%20of%20doing%20this%2C%20since%20I%20ban%20direct%20references%20from%20my%20workbooks%20in%20the%20first%20place.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1022926%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1022926%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESam%2C%20you%20shall%20select%20entire%20formula%20to%20do%20that.%3C%2FP%3E%0A%3CP%3EIn%20cell%3A%3C%2FP%3E%0A%3CP%3EF2%20(or%20double%20click)-%26gt%3BCtrl%2BEnd-%26gt%3BCtrl%2BShift%2BHome-%26gt%3BF4%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20formula%20bar%3C%2FP%3E%0A%3CP%3ECtrl%2BA-%26gt%3BF4%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1022988%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1022988%22%20slang%3D%22en-US%22%3EThank%20you%20PReagan!%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1022991%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1022991%22%20slang%3D%22en-US%22%3EThank%20you%20Peter!%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1023000%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1023000%22%20slang%3D%22en-US%22%3EI%20appreciate%20it%20and%20thank%20you%20Sergei!%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1023012%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1023012%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESam%2C%20you%20are%20welcome%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1023110%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1023110%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F521%22%20target%3D%22_blank%22%3E%40Sergei%20Baklan%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHi%20Sergie%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWhen%20I%20do%26nbsp%3B%3CSPAN%3ECtrl%2BA%20in%20the%20formula%20bar%20it%20doesn't%26nbsp%3Bselect%20the%20entire%20formula.%20It%20doesn't%26nbsp%3Bdo%20anything.%20Am%20i%20doing%20something%20wrong%3F%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%3EThanks%2C%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3ESam%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1023548%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1023548%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EFor%20me%20Ctrl%2BA%20works%20both%20in%20the%20formula%20bar%20and%20the%20cell.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20realise%20that%20my%20proposed%20solution%20was%20overkill%20in%20that%20I%20set%20out%20to%20change%20multiple%20relative%20references%20to%20a%20given%20cell%20without%20changing%20other%20relative%20references%20that%20may%20exist%20within%20the%20same%20formula.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1023588%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1023588%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESam%2C%20perhaps%20you%20are%20not%20on%20latest%20Excel%2C%20couple%20of%20years%20ago%20Ctrl%2BA%20didn't%20work%2C%20see%20for%20example%20our%20discussion%20here%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2FExcel%2FEditing-text-in-a-cell-Ctrl-A-doesn-t-select-all-ctrl-backspace%2Fm-p%2F62354%22%20target%3D%22_blank%22%3Ehttps%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2FExcel%2FEditing-text-in-a-cell-Ctrl-A-doesn-t-select-all-ctrl-backspace%2Fm-p%2F62354%3C%2FA%3E.%20Not%20sure%20when%20it%20was%20introduced.%3C%2FP%3E%0A%3CP%3EAnyway%2C%20select%20in%20formula%20bar%20as%20well%20by%20Ctrl%2BEnd-%26gt%3BCtrl%2BShift%2BHome%20or%20like.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F214174%22%20target%3D%22_blank%22%3E%40Peter%20Bartholomew%3C%2FA%3E%26nbsp%3B%2C%20you%20are%20right%2C%20if%20Ctrl%2BA%20works%20it%20works%20in%20both.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1024628%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1024628%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F521%22%20target%3D%22_blank%22%3E%40Sergei%20Baklan%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EYes%20you%20are%20correct.%20I%26nbsp%3B%3CFONT%20face%3D%22inherit%22%3Ehave%20Excel%202016%20which%20%3C%2FFONT%3Edoesn't%3CFONT%20face%3D%22inherit%22%3E%26nbsp%3Bdo%20it.%26nbsp%3B%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CFONT%20face%3D%22inherit%22%3EThanks!%3C%2FFONT%3E%3C%2FP%3E%3CP%3E%3CFONT%20face%3D%22inherit%22%3ESam%3C%2FFONT%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2083887%22%20slang%3D%22en-US%22%3ERe%3A%20Make%20all%20cells%20references%20in%20a%20long%20formula%20absolute%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2083887%22%20slang%3D%22en-US%22%3E%3CP%3EI%20think%20these%20answers%20are%20over%20complicating%20things.%26nbsp%3B%20I%20would%20do%20a%20search%20G77%20and%20replace%20%24G%2477%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F351459%22%20target%3D%22_blank%22%3E%40SamFares%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Contributor

Hello All:

 

I have a long formula with many different cell references. Is there a way to make all the different cells references absolute in one shot without F4 every cell reference in the formula?

For example i want all G77 in the formula below to be $G$77

=MIN('LC0-1.4D'!G77,'LC1-1.2D +1.6L'!G77,'LC2-1.2D+1.6L,M2M4M6,LL=0 '!G77,'LC3-1.2D+1.6LM1M3M5M7,LL=0 '!G77,'LC4-1.2D+1.6L M3M6,LL=0 '!G77,'LC5-1.2D+1.6LM1M4M7,LL=0 '!G77,'LC6-1.2D+1.6L M2M5,LL=0 '!G77)

 

Thanks,

Sam 

12 Replies

Hello @SamFares,

 

To my knowledge, there is no quicker way than simply using F4 on each cell reference. My suggestion would have been to use find and replace (i.e. find G and replace with $G$) but seeing as though your formula uses cell references beyond the first 26 columns (i.e. LC1, LC2, LL, etc...) this would complicate things. Without creating a macro, I'm afraid my best suggestion is to simply use F4.

 

Sorry if this isn't the answer you were looking for!

@SamFares 

Define a Name to reference the cell (by default it will be an absolute reference) then use 

Apply Names...

on the Name Manager ribbon tab to replace the direct reference by the Name.

 

Not that I have much experience of doing this, since I ban direct references from my workbooks in the first place.

 

best response confirmed by SamFares (Contributor)
Solution

@SamFares 

Sam, you shall select entire formula to do that.

In cell:

F2 (or double click)->Ctrl+End->Ctrl+Shift+Home->F4

 

In formula bar

Ctrl+A->F4

 

Thank you PReagan!
Thank you Peter!
I appreciate it and thank you Sergei!

@SamFares 

Sam, you are welcome

@Sergei Baklan 

 

Hi Sergie:

 

When I do Ctrl+A in the formula bar it doesn't select the entire formula. It doesn't do anything. Am i doing something wrong?

 

Thanks,

Sam

@SamFares 

For me Ctrl+A works both in the formula bar and the cell.

 

I realise that my proposed solution was overkill in that I set out to change multiple relative references to a given cell without changing other relative references that may exist within the same formula.

@SamFares 

Sam, perhaps you are not on latest Excel, couple of years ago Ctrl+A didn't work, see for example our discussion here https://techcommunity.microsoft.com/t5/Excel/Editing-text-in-a-cell-Ctrl-A-doesn-t-select-all-ctrl-b.... Not sure when it was introduced.

Anyway, select in formula bar as well by Ctrl+End->Ctrl+Shift+Home or like.

 

@Peter Bartholomew , you are right, if Ctrl+A works it works in both.

@Sergei Baklan 

 

Yes you are correct. I have Excel 2016 which doesn't do it. 

 

Thanks!

Sam

I think these answers are over complicating things.  I would do a search G77 and replace $G$77 @SamFares