worksheet Name and (Name) properties

  • Thread starter Thread starter Mikhail
  • Start date Start date
M

Mikhail

There are two types of Name property of worksheet. For example, Sheet2
(DataSheet).
When I press F4 to see properties window, I have (name) Sheet2 and name
DataSheet.
In immediate window ? ActiveSheet.Name gives DataSheet.
How can I refer to (name) Sheet2. ? Activesheet.(Name) give error message.

Thanks, Mike510
 
Hi,

The (name) property is the codename of the sheet, the Name
property is the name you see on the Tab. If the Tab name
is "Tabname" and the codename is Sheet1:

Msgbox Worksheets("Tabname").Name

yields "Tabname"

and so does:

Msgbox Sheet1.Name

Regards,

Jan Karel Pieterse
Excel TA/MVP
 
Back
Top