Range.CreateNames Method
Creates names in the specified range, based on text labels in the sheet.
Namespace: Microsoft.Office.Interop.Excel
Assembly: Microsoft.Office.Interop.Excel (in Microsoft.Office.Interop.Excel.dll)
Syntax
'Declaration
Function CreateNames ( _
Top As Object, _
Left As Object, _
Bottom As Object, _
Right As Object _
) As Object
'Usage
Dim instance As Range
Dim Top As Object
Dim Left As Object
Dim Bottom As Object
Dim Right As Object
Dim returnValue As Object
returnValue = instance.CreateNames(Top, _
Left, Bottom, Right)
Object CreateNames(
Object Top,
Object Left,
Object Bottom,
Object Right
)
Parameters
Top
Type: System.ObjectOptional Object. True to create names by using labels in the top row. The default value is False.
Left
Type: System.ObjectOptional Object. True to create names by using labels in the left column. The default value is False.
Bottom
Type: System.ObjectOptional Object. True to create names by using labels in the bottom row. The default value is False.
Right
Type: System.ObjectOptional Object. True to create names by using labels in the right column. The default value is False.
Return Value
Type: System.Object
Remarks
If you don’t specify one of Top, Left, Bottom, or Right, Microsoft Excel guesses the location of the text labels, based on the shape of the specified range.