Auto naming Tabs in a Workbook
Johnny,
Here is a start for you. It renames based on the values of column A.
So, if you start a blank workbook with 3 sheets and write in the cells
A1 = "pig"
A2 = "horse"
A3 = "cow"
then run this program, you will end up with 3 sheets called pig, horse and
cow.
Sub namesheets()
Dim x As Integer
For x = 1 To Sheets.Count
Sheets(x).Name = Cells(x, 1).Value
Next x
End Sub
--
Allllen
"Johnny" wrote:
Is there a way to automatically name/rename a tab based on the cell contents
in a worksheet? Thanks.
|