Style.Name Property (Excel)
Returns a String value that represents the name of the object.
Syntax
expression .Name
expression A variable that represents a Style object.
Example
This example displays the name of style one in the active workbook, first in the language of the macro and then in the language of the user.
With ActiveWorkbook.Styles(1)
MsgBox "The name of the style: " & .Name
MsgBox "The localized name of the style: " & .NameLocal
End With
The following example displays the name of the default ListObject object in sheet1 of the active workbook.
Sub Test
Dim wrksht As Worksheet
Dim oListObj As ListObject
Set wrksht = ActiveWorkbook.Worksheets("Sheet1")
Set oListObj = wrksht.ListObjects(1)
MsgBox oListObj.Name
End Sub