How to create sheet names from a list in Excel?
Here, you have a list of data, and now you want to create a new workbook whose sheets are named with these data. If there are several data in the list, you can choose to create a workbook and rename the sheets one by one manually. But how about hundreds of data in the list? Now I introduce some tricks can create sheet names based on a list of data in Excel.
In Excel, there is no trick to solve this task except VBA code.
1. Press Alt + F11 keys to open the Microsoft Visual Basic for Applications window.
2. Click Insert > Module, and paste below VBA to the new Module window,
VBA: Create sheet names from a list
Sub CreateSheetsFromAList() 'UpdatebyKutoolsforExcel20150916 Dim Rg As Range Dim Rg1 As Range Dim xAddress As String On Error Resume Next xAddress = Application.ActiveWindow.RangeSelection.Address Set Rg = Application.InputBox("Select a range:", "Kutools for Excel", , , , , , 8) If Rg Is Nothing Then Exit Sub For Each Rg1 In Rg If Rg1 <> "" Then Call Sheets.Add(, Sheets(Sheets.Count)) Sheets(Sheets.Count).Name = Rg1.Value End If Next End Sub
3. Click Run or press F5, then a Kutools for Excel dialog pops out to remind you select cells that you want to create sheet name based on.
4. Click OK. Now a series of sheets are created at the end of the current workbook.
If you want to create a new workbook and with the sheet names from a given list of current workbook, you can use Kutools for Excel’s Create Sequence Worksheets.
With Kutools for Excel, you can use the Create Sequence Worksheets utility to quickly create sequence worksheets based on a list of values in a new workbook.
|Kutools for Excel, with more than 300 handy functions, makes your jobs more easier.|
After free installing Kutools for Excel, please do as below:
1. Select the list you need, and click Kutools Plus > Worksheet > Create Sequence Worksheets. See screenshot:
2. In the popping dialog, select Blank worksheet in the list under Base Worksheet, and check Data in a range under Sheet names based on section, and make sure that the range is selected in the textbox. See screenshot:
3. Click Ok, and so far, you can see a new workbook with specific sheet names created.
Tip: If you want to create multiple sheets with the format as same as a specific sheet, you just need to select the sheet name in the list of Base Worksheet, and then specify the sheet names you want based on in the dialog.