Using a named cell in a macro - same workbook

Solved/Closed
Report
-
Posts
1864
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
August 7, 2021
-
Hello,

seems simple but I'm just not getting it....I'm using excel 2003 and am trying to use a named cell on one sheet in a macro on a different sheet (which will be the active sheet) - any clues?

2 replies

Posts
1864
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
August 7, 2021
803
use

range(name of the cell in double quotes).(any method or property)
for e.g. the name is rv
range("rv").select
thank you -it worked perfectly. Would you know the other bit - is it best to use a select case to run through all of the headings in row 1 (rows with data) or an if then statement.
Posts
1864
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
August 7, 2021
803
bot are same. I am personally more comfortable with if then rather than select. It is only personal prejudice. select case is elegant see the code.