Home

Can INDIRECT be used to dynamically alter the second range reference in a Named Range

%3CLINGO-SUB%20id%3D%22lingo-sub-914197%22%20slang%3D%22en-US%22%3ECan%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914197%22%20slang%3D%22en-US%22%3E%3CP%3EI%20have%20a%20workbook%20that%20retrieves%20data%20from%20another%20spreadsheet%2C%20the%20latter%20being%20downloaded%20from%20my%20brokerage.%20Occasionally%20the%20number%20of%20rows%20in%20the%20downloaded%20sheet%20goes%20up%20or%20down%2C%20based%20on%20buying%20or%20selling%20securities.%20After%20retrieving%20the%20data%20into%20the%20active%20workbook%2C%20I%20have%20a%20named%20range%20that%20includes%20all%20the%20data%20i%20need%3B%20and%20I%20then%20use%20VLOOKUP%20to%20access%20whatever%20data%20I%20need%20elsewhere%20in%20the%20workbook.%20As%20noted%20the%20range%20usually%20is%20stable%2C%20but%20when%20there's%20a%20new%20row%20or%20two%2C%20or%20when%20I've%20sold%20some%20securities%20so%20the%20number%20of%20rows%20declines%2C%20I've%20been%20manually%20altering%20the%20range%20reference%20in%20the%20Named%20Range%20box.%3C%2FP%3E%3CP%3EToday%20I%20tried%20to%20used%20COUNT%26nbsp%3B%20to%20capture%20the%20number%20of%20rows%20dynamically%2C%20and%20then%20created%20an%20A1%20reference%20and%20tried%20to%20use%20INDIRECT%20to%20reference%20that%20from%20within%20the%20Insert%20Name%20dialog%20box.%20It%20appeared%20to%20accept%20the%20INDIRECT%2C%20but%20the%20named%20range%20didn't%20work.%20So%20my%20question%20is%20whether%20that's%20even%20possible.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-914197%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-914297%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914297%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F425987%22%20target%3D%22_blank%22%3E%40mathetes%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELet%20me%20play%20with%20simple%20sample.%20Assume%20on%20Sheet2%20we%20have%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20121px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F137506i4E442E49A2BADCAA%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22image.png%22%20title%3D%22image.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3Eand%20in%20Sheet1%20we'd%20like%20to%20find%20element%20form%20here%20on%20position%20defined%20in%20A3%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20151px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F137507iC1410B8D1F622ECC%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22image.png%22%20title%3D%22image.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3EDirect%20formula%20will%20be%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DINDEX(Sheet2!%24E%243%3A%24E%2415%2C%24A%243)%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EWith%20INDIRECT%20it's%20like%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DINDEX(INDIRECT(%24A%241%26amp%3B%20%22!%22%20%26amp%3B%20%22%24E%243%3A%22%20%26amp%3B%20%22%24E%2415%22)%2C%24A%243)%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EFor%20the%20dynamic%20range%2C%20assuming%20first%20cell%20is%20fixed%2C%20we%20shall%20only%20receive%20an%20address%20of%20the%20last%20cell%20in%20the%20range.%20If%20we%20calculate%20in%20B1%20the%20size%20of%20the%20range%20as%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DCOUNTA(INDIRECT(%24A%241%26amp%3B%22!%24E%3A%24E%22))%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3Ewe%20may%20substitute%20E15%20as%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DINDEX(INDIRECT(%24A%241%26amp%3B%20%22!%22%20%26amp%3B%20%22%24E%243%3A%22%20%26amp%3B%20ADDRESS(%24B%241%2B2%2CCOLUMN(%24E%243)))%2C%24A%243)%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3EHere%20it%20is%20assumed%20ranges%20for%20all%20sheets%20are%20in%20column%20E%20and%20we%20don't%20insert%2Fdelete%20columns%20in%20first%20sheet%20with%20formulas.%20When%20above%20will%20be%20bit%20more%20complex%2C%20but%20idea%20is%20the%20same.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-914340%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914340%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%3EThat%20might%20work%20but%20it's%20not%20what%20my%20(unclear)%20question%20was%20looking%20for.%20Let%20me%20see%20if%20i%20can%20restate%20it.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20have%20a%20named%20range%2C%20using%20Insert....Name....%20and%20in%20the%20dialog%20box%20the%20range%20is%20specified%20as%20shown%20here%3A%3C%2FP%3E%3CDIV%20class%3D%22mceNonEditable%20lia-copypaste-placeholder%22%3E%3CDIV%20class%3D%22mceNonEditable%20lia-copypaste-placeholder%22%3E%26nbsp%3B%3C%2FDIV%3E%3CDIV%20class%3D%22mceNonEditable%20lia-copypaste-placeholder%22%3E%26nbsp%3B%3C%2FDIV%3E%3C%2FDIV%3E%3CP%3EAnd%20I%20then%20use%20VLOOKUP%20to%20reference%20any%20number%20of%20cells%20in%20that%20named%20range%20by%20formulas%20such%20as%20%3DVLOOKUP(%24A23%2CCurrentActuals%2CC%245%2C0)%26nbsp%3B%26nbsp%3B%20That%20works%20perfectly.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20problem%20is%20that%20occasionally%20I%20add%20a%20row%20to%20the%20range%20%22CurrentActuals%22%20and%20have%20always%20been%20changing%20that%20last%20reference%20manually%20to%20%22%24U%2460%22%20or%20%22SU%2465%22%26nbsp%3B%26nbsp%3B%20I%20am%20wanting%20to%20see%20if%20I%20can%20use%20INDIRECT%20to%20allow%20the%20named%20range%20to%20change%20its%20parameters.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESo%20I%20created%20a%20formula%20in%20cell%20J1%20that%20dynamically%20changes%20so%20%3CU%3E%3CSTRONG%3Eit%20reads%26nbsp%3B%22%24U%2460%22%20or%20%22%24U%2465%22%3C%2FSTRONG%3E%3C%2FU%3E%20%26nbsp%3B%20and%20then%20refer%20to%20cell%20J1%20it%20in%20the%20Define%20Name%20dialog%20box%20by%20means%20of%20the%20Function%20INDIRECT.%20The%20Dialog%20Box%20accepts%20the%20entry%20without%20objection%2C%20and%20shows%20as%20displayed%20here%3A%26nbsp%3B%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F137512i81BA6EBBE17FAD4A%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22image.png%22%20title%3D%22image.png%22%20%2F%3E%3C%2FSPAN%3E%20%26nbsp%3B%3C%2FP%3E%3CP%3EIt%20totally%20accepts%20the%20entry%20of%20the%20INDIRECT%20function%20(In%20fact%2C%20in%20creating%20this%20image%2C%20I%20entered%20it%20all%20in%20lower%20case%20and%20then%20came%20back%20to%20clip%20the%20screen%20shot%20and%20as%20you%20can%20see%20it%20not%20only%20accepted%20it%2C%20but%20changed%20it%20to%20upper%20case.%20Suggesting%20to%20me%20that%20it%20would%20work.%26nbsp%3B%20But%20it%20doesn't.%20And%20yet%20cell%20%24J%241%20reads%20exactly%20as%20the%20cell%20reference%20in%20the%20first%20image....%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESo%20my%20question%20is%20simply%20phrased%20perhaps%20in%20two%20parts%3A%20(1)%20Does%20INDIRECT%20work%20as%20part%20of%20a%20cell%20reference%20in%20a%20named%20range%3F%20(2)%20If%20so%2C%20is%20there%20a%20syntax%20that%20somehow%20I'm%20missing%3F%20Either%20in%20the%20Cell%20itself--e.g.%2C%20should%20all%20of%20it%20be%20surrounded%20by%20quotation%20marks%3F--or%20in%20the%20spot%20in%20the%20Dialog%20box%20where%20the%20named%20range%20is%20specified%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EDoes%20this%20make%20more%20sense%3F%20It%20seems%20to%20me%20that%20it%20should%20be%20very%20straightforward%2C%20especially%20given%20that%20the%20dialog%20box%20accepted%20the%20use%20of%20INDIRECT......%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-914343%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914343%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%26nbsp%3B%20Hmm...that%20reply%20omitted%20an%20image%20I'd%20put%20in%20it.%20Here%20it%20is.%20This%20is%20the%20Named%20Range%20dialog%20box%20%3CEM%3E%3CSTRONG%3Ewithout%3C%2FSTRONG%3E%3C%2FEM%3E%20the%20use%20of%20INDIRECT.%20And%20it%20works%20just%20fine%2C%20as%20noted.%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F137517i544B69D89F6B1957%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22image.png%22%20title%3D%22image.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-914422%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914422%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F425987%22%20target%3D%22_blank%22%3E%40mathetes%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ECould%20you%20use%20Tables%20to%20store%20the%20data%20you%20need.%26nbsp%3B%20As%20you%20add%20or%20remove%20data%20your%20formula%20would%20automatically%20change%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-914466%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914466%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F9832%22%20target%3D%22_blank%22%3E%40Wyn%20Hopkins%3C%2FA%3E%26nbsp%3B%26nbsp%3B%20I%20do%20have%20the%20data%20in%20the%20form%20of%20a%20table%2C%20using%20VLOOKUP%20to%20access%20it.%20The%20problem%20is%20that%20the%20VLOOKUP%20refers%20to%20the%20table%20by%20Name%2C%20using%20the%20Named%20Range%20capability.%20And%20the%20difficulty%20I%20was%20having%20had%20to%20do%20with%20enabling%20that%20named%20range%20to%20vary%20in%20size%20without%20re-specifying%20the%20dimensions.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAs%20sometimes%20happens%2C%20%3CSTRONG%3E%3CEM%3EI%20have%20now%20found%20a%20very%20functional%20answer%20and%20it%20works%20like%20a%20charm%3C%2FEM%3E%3C%2FSTRONG%3E.%20I%20hadn't%20realized%20you%20could%20write%20a%20full%20formula%20in%20the%20box%20where%20you%20give%20the%20range%20references.%20Searching%20via%20Google%20led%20me%20to%20this%20page%20%3CA%20href%3D%22https%3A%2F%2Fwww.contextures.com%2FxlNames01.html%23Dynamic%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fwww.contextures.com%2FxlNames01.html%23Dynamic%3C%2FA%3E%20where%20the%20resource%20describes%20how%20to%20use%20the%20%3CSTRONG%3EOFFSET%3C%2FSTRONG%3E%20function%20to%20specify%20the%20dimensions%2C%20doing%20so%20within%20the%20Range%20Name%20Dialog%20box.%26nbsp%3B%20I%20have%20now%20a%20working%20solution%20by%20that%20means.%20The%20full%20formula%20doesn't%20display%20in%20this%20image%2C%20but%20essentially%20it%20reads%20%3CSTRONG%3E%3DOFFSET(TopLeftCorner%2C0%2C0%2CNumberOfRows%2CNumberOfColumns)%3C%2FSTRONG%3E%20with%20those%20last%20two%20in%20the%20form%20of%20cell%20references%20where%20those%20numbers%20can%20change%20dynamically%2C%20and%20the%20%220%2C0%22%20at%20the%20start%20just%20says%2C%20begin%20right%20at%20that%20top%20left%20corner%20with%200%20offset).%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F137567i3020D97816C09A2A%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22image.png%22%20title%3D%22image.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3BSo%2C%20folks%2C%20THAT%20is%20how%20to%20have%20the%20size%20of%20a%20named%20range%20be%20maintained%20dynamically.%26nbsp%3B%20INDIRECT%20is%20not%20at%20all%20necessary%20(and%20I%20wasn't%20using%20it%20correctly%20anyway)....but%20this%20is%20a%20far%20more%20elegant%20solution.%3C%2FP%3E%3CP%3Emathetes%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-914978%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-914978%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F425987%22%20target%3D%22_blank%22%3E%40mathetes%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EGlad%20you%20found%20a%20solution%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhen%20you%20say%20your%20data%20is%20in%20a%20Table%2C%20so%20you%20mean%20a%20properly%20formatted%20Excel%20Table%20(with%20a%20capital%20T)%20like%20this%20one...%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20278px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F137610i1EC32B7F2C71029F%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22image.png%22%20title%3D%22image.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-915263%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-915263%22%20slang%3D%22en-US%22%3EI%20thought%20that%20was%20what%20I%20meant%2C%20but%20l%20am%20probably%20using%20more%20of%20a%20Data%20Table%20approach...definitely%20rows%20of%20data%20with%20header%2C%20but%20not%20%22Excel%20Tables%22--that's%20a%20function%20or%20capability%20that's%20come%20along%20more%20recently%20in%20Excel's%20history.%20But%20it%20looked%20to%20me%2C%20as%20I%20researched%20it%2C%20as%20if%20that%20still%20requires%20a%20%22RESIZE%22%20command%20when%20you%20add%20rows%20or%20columns...No%3F%20Bottom%20line%2C%20it%20could%20be%20yet%20another%20way%20to%20skin%20the%20same%20cat.%20Excel%20does%20have%20some%20redundancies%20like%20that.%20Thanks%20for%20pointing%20that%20one%20out.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-915308%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-915308%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F425987%22%20target%3D%22_blank%22%3E%40mathetes%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20might%20find%20this%20of%20interest%2C%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Faccessanalytic.com.au%2Fdynamic-data-validation-tables-excel%2F%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Faccessanalytic.com.au%2Fdynamic-data-validation-tables-excel%2F%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-915333%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-915333%22%20slang%3D%22en-US%22%3EThanks%2C%20Wyn.%20This%20has%20been%20a%20most%20interesting%20exchange.%20In%20my%20career%20(now%20retired)%20I%20was%20director%20of%20the%20HR%2FPayroll%20database%20at%20my%20company%2C%20and%20became%20in%20the%20process%20very%20adept%20at%20topics%20like%20data%20integrity%20(in%20Excel%2C%20facilitated%20by%20your%20data%20validation%20methods).%20I've%20used%20Excel%20data%20validation%20for%20a%20decade%20or%20more.%20And%20used%20most%20of%20Excel's%20D____%20database%20functions.%20The%20TABLE%20capability%20per%20se%20is%20new%20to%20me...as%20you%20noticed%2C%20I%20was%20relying%20on%20Named%20Range%20and%20wanting%20to%20dynamically%20define%20the%20range%20(and%20now%20do%20so%20using%20OFFSET)...anyway%2C%20I%20miss%20the%20days%20of%20printed%20manuals%20(which%20I%20actually%20read%20periodically%2C%20to%20uncover%20ways%20to%20do%20things%20more%20easily%20than%20I'd%20been%20doing%20them).%20On-line%20references%20are%20useful%2C%20but%20you%20don't%20%22stumble%20across%22%20the%20unexpected.%20Like%20in%20this%20case%2C%20I%20didn't%20realize%20Excel%20had%20come%20up%20with%20new%20ways%20to%20conceive%20of%20and%20use%20tables.%20I've%20added%20your%20site%20to%20my%20reference%20bookmarks.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-915425%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-915425%22%20slang%3D%22en-US%22%3EYou're%20most%20welcome%2C%3CBR%20%2F%3E%3CBR%20%2F%3EThe%20pace%20of%20change%20and%20what's%20now%20possible%20in%20Excel%20is%20amazing.%20Having%20started%20with%20Excel%20back%20in%201998%20it%20hardly%20change%20for%2010%20years%20but%20its%20been%20amazing%20to%20see%20all%20the%20changes%20in%20the%20last%2010.%20The%20last%205%20years%20has%20been%20even%20more%20significant%20with%20the%20advent%20of%20Power%20Query%20and%20Power%20Pivot%20in%20Excel%2C%20truly%20game%20changing%20features%20that%20still%20far%20too%20few%20folks%20know%20about.%3CBR%20%2F%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-915974%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-915974%22%20slang%3D%22en-US%22%3EOFFSET%20is%20volatile%2C%20I%E2%80%99m%20certain%20that%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F9832%22%20target%3D%22_blank%22%3E%40Wyn%20Hopkins%3C%2FA%3E%20could%20recommend%20a%20non-volatile%20formula%20using%20INDEX.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-916022%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-916022%22%20slang%3D%22en-US%22%3EWell%2C%20depending%20on%20what%20you%20mean%20by%20%22volatile%2C%22%20that%20could%20be%20exactly%20what%20I%20want%2C%20in%20the%20sense%20of%20%22dynamic%22%20or%20%22changing%20with%20variations%20in%20other%20data%22...that%20method%20was%20one%20I%20found%20online%2C%20as%20noted%20above.%3CBR%20%2F%3EIf%20you%20mean%20%22unreliable%22%20then%2C%20no%2C%20that's%20not%20what%20I%20want.%20Time%20will%20tell.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-916131%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-916131%22%20slang%3D%22en-US%22%3EVolatile%2C%20in%20Excel%20terms%2C%20means%20slow.%20For%20the%20explanation%2C%20I%E2%80%99ll%20leave%20that%20to%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F9832%22%20target%3D%22_blank%22%3E%40Wyn%20Hopkins%3C%2FA%3E.%20Perhaps%2C%20he%E2%80%99s%20busy%20now.%20Indubitably%2C%20%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%20could%20do%20so.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-916156%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-916156%22%20slang%3D%22en-US%22%3EVolatile%20means%20slow%3F!%20Really.%20That's%20an%20interesting%20notion%3B%20would%20not%20have%20been%20standard%20English%2C%20I%20wouldn't%20think..%3CBR%20%2F%3EIn%20any%20event%2C%20I%20can%20see%20why%20OFFSET%20might%20be%20slow%20in%20Excel--there's%20simply%2C%20potentially%2C%20a%20lot%20to%20resolve%2C%20so%20if%20it's%20being%20used%20a%20lot%2C%20repeatedly%2C%20or%20in%20multiple%20spots%20in%20a%20given%20workbook%2C%20it%20could%20indeed%20slow%20things%20down.%3CBR%20%2F%3EIn%20the%20use%20that%20I'm%20making%20of%20it--simply%20to%20define%20the%20range%20to%20which%20a%20Name%20is%20being%20applied%2C%20it%20gets%20used%20once%20upon%20opening%20a%20sheet%2C%20and%20never%20again.%20Simply%20used%20to%20take%20care%20of%20a%20data%20table%20that%20can%20change%20its%20dimensions%20from%20time%20to%20time%2C%20and%20do%20so%20without%20requiring%20manual%20redefinition.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-916160%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-916160%22%20slang%3D%22en-US%22%3EI%20convinced%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F20200%22%20target%3D%22_blank%22%3E%40Kevin%20Lehrbass%3C%2FA%3E%20to%20shift%20from%20OFFSET%20to%20INDEX%20here%3A%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fwww.myspreadsheetlab.com%2Fdynamic-ranges-using-index-function%2F%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fwww.myspreadsheetlab.com%2Fdynamic-ranges-using-index-function%2F%3C%2FA%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-916210%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-916210%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F425987%22%20target%3D%22_blank%22%3E%40mathetes%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EVolatile%20function%20doesn't%20mean%20that%20function%20is%20slow%20itself.%20Volatile%20function%20means%20the%20function%20which%20is%20recalculating%20every%20time%20when%20Excel%20recalculates%20something%20else.%20Obvious%20example%20of%20volatile%20function%20is%20NOW()%20-%20it's%20extremely%20fast%20itself%2C%20but%20if%20we%20have%20lot%20of%20them%20in%20different%20cells%20and%20formulas%20entire%20their%20recalculation%20on%20every%20click%20could%20significantly%20slow%20overall%20Excel%20performance.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EMy%20view%20-%20yes%2C%20in%20general%20it's%20better%20to%20avoid%20volatile%20functions.%20On%20the%20other%20hand%20that's%20not%20must.%20With%20proper%20design%20of%20Excel%20workbook%20volatile%20functions%20could%20be%20effective%20enough%2C%20especially%20if%20take%20into%20account%20efforts%20on%20maintenance%20-%20they%20don't%20cost%20few%20saved%20milliseconds%20in%20calculations.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EMore%20about%20that%20in%20two%20good%20articles%3C%2FP%3E%0A%3CP%3E%3CA%20title%3D%22Excel%20performance%3A%20Tips%20for%20optimizing%20performance%20obstructions%22%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Foffice%2Fvba%2Fexcel%2Fconcepts%2Fexcel-performance%2Fexcel-tips-for-optimizing-performance-obstructions%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3EExcel%20performance%3A%20Tips%20for%20optimizing%20performance%20obstructions%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CA%20title%3D%22Excel%20performance%3A%20Improving%20calculation%20performance%22%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Foffice%2Fvba%2Fexcel%2Fconcepts%2Fexcel-performance%2Fexcel-improving-calcuation-performance%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3EExcel%20performance%3A%20Improving%20calculation%20performance%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAnd%20citation%20from%20the%20latest%3A%3C%2FP%3E%0A%3CDIV%20class%3D%22mainContainer%20%20uhf-container%20has-top-padding%20%20has-default-focus%22%20data-bi-name%3D%22body%22%3E%0A%3CDIV%20class%3D%22columns%20has-large-gaps%20is-gapless-mobile%20%22%3E%0A%3CSECTION%20class%3D%22primary-holder%20column%20is-two-thirds-tablet%20is-three-quarters-desktop%22%3E%0A%3CDIV%20class%3D%22columns%20is-gapless-mobile%20has-large-gaps%20%22%3E%0A%3CDIV%20id%3D%22main-column%22%20class%3D%22column%20%20is-full%20is-four-fifths-desktop%20%22%3E%0A%3CUL%3E%0A%3CLI%3E%3CP%3EAvoid%20volatile%20functions%20such%20as%20%3CSTRONG%3EINDIRECT%3C%2FSTRONG%3E%20and%20%3CSTRONG%3EOFFSET%3C%2FSTRONG%3E%20where%20you%20can%2C%20unless%20they%20are%20significantly%20more%20efficient%20than%20the%20alternatives.%20(Well-designed%20use%20of%20%3CSTRONG%3EOFFSET%3C%2FSTRONG%3E%20is%20often%20fast.)%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3C%2FDIV%3E%0A%3C%2FDIV%3E%0A%3C%2FSECTION%3E%0A%3C%2FDIV%3E%0A%3C%2FDIV%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-916224%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-916224%22%20slang%3D%22en-US%22%3EWell%20explained%2C%20as%20always!%20Nonetheless%2C%20non-volatile%20alternatives%20are%20preferable%2C%20as%20can%20be%20gleaned%20from%20the%20cited%20article.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-998743%22%20slang%3D%22en-US%22%3ERe%3A%20Can%20INDIRECT%20be%20used%20to%20dynamically%20alter%20the%20second%20range%20reference%20in%20a%20Named%20Range%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-998743%22%20slang%3D%22en-US%22%3E%3CP%3EI%20agree%20that%20if%20volatile%20functions%20are%20avoidable%20then%20we%20should%20avoid%20them%20%3CLI-EMOJI%20id%3D%22lia_slightly-smiling-face%22%20title%3D%22%3Aslightly_smiling_face%3A%22%3E%3C%2FLI-EMOJI%3E%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F280482%22%20target%3D%22_blank%22%3E%40Twifoo%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EOften%20the%20non%20volatile%20formula%20alternative%20has%20more%20complex%20syntax%20but%20for%20serious%20development%20we%20should%20take%20the%20time%20to%20avoid%20volatile%20functions%20whenever%20possible.%3C%2FP%3E%3CP%3EObviously%2C%20as%26nbsp%3B%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%20mentioned%20above%2C%20there%20are%20times%20when%20NOW()%20(volatile)%20is%20unavoidable.%3C%2FP%3E%3CP%3EThanks%20to%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F280482%22%20target%3D%22_blank%22%3E%40Twifoo%3C%2FA%3E%20for%20various%20non%20volatile%20alternative%20solutions%20on%20my%20blog%20this%20year!%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Frequent Contributor

I have a workbook that retrieves data from another spreadsheet, the latter being downloaded from my brokerage. Occasionally the number of rows in the downloaded sheet goes up or down, based on buying or selling securities. After retrieving the data into the active workbook, I have a named range that includes all the data i need; and I then use VLOOKUP to access whatever data I need elsewhere in the workbook. As noted the range usually is stable, but when there's a new row or two, or when I've sold some securities so the number of rows declines, I've been manually altering the range reference in the Named Range box.

Today I tried to used COUNT  to capture the number of rows dynamically, and then created an A1 reference and tried to use INDIRECT to reference that from within the Insert Name dialog box. It appeared to accept the INDIRECT, but the named range didn't work. So my question is whether that's even possible.

18 Replies

@mathetes 

Let me play with simple sample. Assume on Sheet2 we have

image.png

and in Sheet1 we'd like to find element form here on position defined in A3

image.png

Direct formula will be 

=INDEX(Sheet2!$E$3:$E$15,$A$3)

With INDIRECT it's like

=INDEX(INDIRECT($A$1& "!" & "$E$3:" & "$E$15"),$A$3)

For the dynamic range, assuming first cell is fixed, we shall only receive an address of the last cell in the range. If we calculate in B1 the size of the range as

=COUNTA(INDIRECT($A$1&"!$E:$E"))

we may substitute E15 as

=INDEX(INDIRECT($A$1& "!" & "$E$3:" & ADDRESS($B$1+2,COLUMN($E$3))),$A$3)

Here it is assumed ranges for all sheets are in column E and we don't insert/delete columns in first sheet with formulas. When above will be bit more complex, but idea is the same.

@Sergei Baklan 

That might work but it's not what my (unclear) question was looking for. Let me see if i can restate it.

 

I have a named range, using Insert....Name.... and in the dialog box the range is specified as shown here:

 
 

And I then use VLOOKUP to reference any number of cells in that named range by formulas such as =VLOOKUP($A23,CurrentActuals,C$5,0)   That works perfectly.

 

The problem is that occasionally I add a row to the range "CurrentActuals" and have always been changing that last reference manually to "$U$60" or "SU$65"   I am wanting to see if I can use INDIRECT to allow the named range to change its parameters.

 

So I created a formula in cell J1 that dynamically changes so it reads "$U$60" or "$U$65"   and then refer to cell J1 it in the Define Name dialog box by means of the Function INDIRECT. The Dialog Box accepts the entry without objection, and shows as displayed here: image.png  

It totally accepts the entry of the INDIRECT function (In fact, in creating this image, I entered it all in lower case and then came back to clip the screen shot and as you can see it not only accepted it, but changed it to upper case. Suggesting to me that it would work.  But it doesn't. And yet cell $J$1 reads exactly as the cell reference in the first image....

 

So my question is simply phrased perhaps in two parts: (1) Does INDIRECT work as part of a cell reference in a named range? (2) If so, is there a syntax that somehow I'm missing? Either in the Cell itself--e.g., should all of it be surrounded by quotation marks?--or in the spot in the Dialog box where the named range is specified?

 

Does this make more sense? It seems to me that it should be very straightforward, especially given that the dialog box accepted the use of INDIRECT......

@Sergei Baklan   Hmm...that reply omitted an image I'd put in it. Here it is. This is the Named Range dialog box without the use of INDIRECT. And it works just fine, as noted.image.png

@mathetes 

 

Could you use Tables to store the data you need.  As you add or remove data your formula would automatically change?

@Wyn Hopkins   I do have the data in the form of a table, using VLOOKUP to access it. The problem is that the VLOOKUP refers to the table by Name, using the Named Range capability. And the difficulty I was having had to do with enabling that named range to vary in size without re-specifying the dimensions.

 

As sometimes happens, I have now found a very functional answer and it works like a charm. I hadn't realized you could write a full formula in the box where you give the range references. Searching via Google led me to this page https://www.contextures.com/xlNames01.html#Dynamic where the resource describes how to use the OFFSET function to specify the dimensions, doing so within the Range Name Dialog box.  I have now a working solution by that means. The full formula doesn't display in this image, but essentially it reads =OFFSET(TopLeftCorner,0,0,NumberOfRows,NumberOfColumns) with those last two in the form of cell references where those numbers can change dynamically, and the "0,0" at the start just says, begin right at that top left corner with 0 offset).

image.png

 So, folks, THAT is how to have the size of a named range be maintained dynamically.  INDIRECT is not at all necessary (and I wasn't using it correctly anyway)....but this is a far more elegant solution.

mathetes

@mathetes 

 

Glad you found a solution

 

When you say your data is in a Table, so you mean a properly formatted Excel Table (with a capital T) like this one...

 

image.png

 

 

I thought that was what I meant, but l am probably using more of a Data Table approach...definitely rows of data with header, but not "Excel Tables"--that's a function or capability that's come along more recently in Excel's history. But it looked to me, as I researched it, as if that still requires a "RESIZE" command when you add rows or columns...No? Bottom line, it could be yet another way to skin the same cat. Excel does have some redundancies like that. Thanks for pointing that one out.
Thanks, Wyn. This has been a most interesting exchange. In my career (now retired) I was director of the HR/Payroll database at my company, and became in the process very adept at topics like data integrity (in Excel, facilitated by your data validation methods). I've used Excel data validation for a decade or more. And used most of Excel's D____ database functions. The TABLE capability per se is new to me...as you noticed, I was relying on Named Range and wanting to dynamically define the range (and now do so using OFFSET)...anyway, I miss the days of printed manuals (which I actually read periodically, to uncover ways to do things more easily than I'd been doing them). On-line references are useful, but you don't "stumble across" the unexpected. Like in this case, I didn't realize Excel had come up with new ways to conceive of and use tables. I've added your site to my reference bookmarks.
You're most welcome,

The pace of change and what's now possible in Excel is amazing. Having started with Excel back in 1998 it hardly change for 10 years but its been amazing to see all the changes in the last 10. The last 5 years has been even more significant with the advent of Power Query and Power Pivot in Excel, truly game changing features that still far too few folks know about.
OFFSET is volatile, I’m certain that @Wyn Hopkins could recommend a non-volatile formula using INDEX.
Well, depending on what you mean by "volatile," that could be exactly what I want, in the sense of "dynamic" or "changing with variations in other data"...that method was one I found online, as noted above.
If you mean "unreliable" then, no, that's not what I want. Time will tell.
Volatile, in Excel terms, means slow. For the explanation, I’ll leave that to @Wyn Hopkins. Perhaps, he’s busy now. Indubitably, @Sergei Baklan could do so.
Volatile means slow?! Really. That's an interesting notion; would not have been standard English, I wouldn't think..
In any event, I can see why OFFSET might be slow in Excel--there's simply, potentially, a lot to resolve, so if it's being used a lot, repeatedly, or in multiple spots in a given workbook, it could indeed slow things down.
In the use that I'm making of it--simply to define the range to which a Name is being applied, it gets used once upon opening a sheet, and never again. Simply used to take care of a data table that can change its dimensions from time to time, and do so without requiring manual redefinition.

@mathetes 

Volatile function doesn't mean that function is slow itself. Volatile function means the function which is recalculating every time when Excel recalculates something else. Obvious example of volatile function is NOW() - it's extremely fast itself, but if we have lot of them in different cells and formulas entire their recalculation on every click could significantly slow overall Excel performance.

 

My view - yes, in general it's better to avoid volatile functions. On the other hand that's not must. With proper design of Excel workbook volatile functions could be effective enough, especially if take into account efforts on maintenance - they don't cost few saved milliseconds in calculations.

 

More about that in two good articles

Excel performance: Tips for optimizing performance obstructions 

Excel performance: Improving calculation performance 

And citation from the latest:

  • Avoid volatile functions such as INDIRECT and OFFSET where you can, unless they are significantly more efficient than the alternatives. (Well-designed use of OFFSET is often fast.)

Well explained, as always! Nonetheless, non-volatile alternatives are preferable, as can be gleaned from the cited article.

I agree that if volatile functions are avoidable then we should avoid them @Twifoo 

Often the non volatile formula alternative has more complex syntax but for serious development we should take the time to avoid volatile functions whenever possible.

Obviously, as @Sergei Baklan mentioned above, there are times when NOW() (volatile) is unavoidable.

Thanks to @Twifoo for various non volatile alternative solutions on my blog this year! 

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
46 Replies
Extentions Synchronization
Deleted in Discussions on
3 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
29 Replies
flashing a white screen while open new tab
Deleted in Discussions on
14 Replies
Security Community Webinars
Valon_Kolica in Security, Privacy & Compliance on
13 Replies