How to define a relative named range in VBA
Or in code (missed that):
ActiveWorkbook.Names.Add Name:="CellBelow", _
RefersToR1C1:="=INDIRECT(""r[1]c"",FALSE)"
Dave Peterson wrote:
How about:
Insert|Name|Define
Cellbelow
=INDIRECT("r[1]c",FALSE)
John Broderick wrote:
Thanks Bob,
this does the same thing as Insert Name /Define, which is the original
question I asked.
However I now realize when I use CellBelow on any sheet it always refers to
the original sheet that was active when I defined it.
I want CellBelow to refer to the cell below the active cell on the active
sheet, not the original sheet.
JB
--
Dave Peterson
--
Dave Peterson
|