RowNumbers Property Example

This example adds row numbers and field names to the query table.

With Worksheets(1).QueryTables("ExternalData1")
    .RowNumbers = True
    .FieldNames = True
    .Refresh
End With