跳到主要内容

如何在Excel中重命名多个工作表?

通常,要在Excel中重命名工作表,我们可以快速双击工作表选项卡,或右键单击工作表选项卡以选择“重命名”命令以重命名工作表。 在Excel中重命名一个或两个工作表非常方便,但是如果我们想在一个操作中重命名多个工作表,该怎么办?

doc重命名工作表6

使用重命名命令重命名工作表

使用便捷的工具轻松地重命名多个工作表

使用VBA代码重命名多个工作表


使用重命名命令重命名工作表


我们可以使用以下命令快速重命名Excel中的工作表: 重命名 根据以下过程命令:

右键单击要重命名的工作表标签,然后选择 重命名 右键单击菜单中的命令。 或双击工作表选项卡以重命名工作表。 然后键入一个新名称,然后按 输入 重命名它的密钥,请参见屏幕截图:

有了这个 重命名 命令,一次只能重命名一个工作表,为了重命名多个工作表,请重复上述操作。

使用每个工作表中的指定文本、单元格值或特定单元格值轻松重命名多个工作表

Kutools for Excel 的重命名多个工作表实用程序可以帮助您轻松地在 Excel 中同时重命名多个工作表。 立即获得 30 天的全功能免费试用!

Kutools for Excel - 使用 300 多种基本工具增强 Excel 功能。 享受全功能 30 天免费试用,无需信用卡! 立即行动吧!


使用便捷的工具轻松地重命名多个工作表

Kutools for Excel 的重命名多个工作表工具对于重命名当前工作簿的所有工作表或选定的特定工作表非常方便。

使用此工具,您可以通过在现有工作表名称之前或之后添加额外的内容来快速重命名所有工作表或选定的特定工作表,或用新名称替换原始工作表名称。 您还可以使用范围单元格的内容来重命名所有工作表或选定的工作表。

下载并安装 Kutools for Excel,点击 Kutools 加 > 工作表 > 重命名工作表 打开 重命名多个工作表 对话框。 那么请执行以下操作:

场景 1. 使用 Kutools for Excel 重命名具有特定数据的多个工作表

doc重命名工作表5

  1. 从工作表中选择要重命名的工作表 工作表 名单。
  2. 选择您要重命名其下的工作表的一种类型 重命名选项。
  3. 将具体数值输入 从输入框.
  4. 点击 OK。 您将得到以下结果:

doc重命名工作表6

场景 2. 使用 Kutools for Excel 用单元格值重命名多个工作表

doc重命名工作表7

  1. 从工作表中选择要重命名的工作表 工作表 名单。
  2. 选择您要重命名其下的工作表的一种类型 重命名选项。
  3. 点击  doc按钮 按钮以选择您要基于其下的工作表命名的单元格值 从特定范围 部分。
  4. 点击 OK。 您将得到以下结果:

doc重命名工作表8

场景 3. 使用 Kutools for Excel 在每个工作表中使用特定单元格值重命名多个工作表

doc重命名工作表9

  1. 从工作表中选择要重命名的工作表 工作表 名单。
  2. 选择您要重命名其下的工作表的一种类型 重命名选项。
  3. 点击  doc按钮 按钮以选择您要基于其下的工作表命名的特定单元格值 重命名具有特定单元格的工作表 部分。
  4. 点击 OK。工作表名称已使用每个工作表中的特定单元格值重命名。

doc重命名工作表10

Tips::要使用此功能,您应该安装 Kutools for Excel 首先,请 点击下载并享受 30 天免费试用 现在。

使用VBA代码重命名多个工作表

在这里,我将向您介绍两个VBA代码以重命名多个工作表。

代码 1. VBA 代码可一次按您想要的名称重命名多个工作表

使用以下VBA代码,您可以快速重命名当前工作簿的所有工作表,这些工作表的工作表名称带有相同的前缀,例如:KTE-order1,KTE-order 2和KTE-order 3…

1. 点击 开发商 > Visual Basic中和点击 插页 > 模块 ,在 Microsoft Visual Basic应用程序Windows.

2. 请复制以下代码并将其粘贴到 模块.

VBA:通过输入特定名称重命名所有工作表

Sub ChangeWorkSheetName()
'Updateby20140624
Dim Rng As Range
Dim WorkRng As Range
On Error Resume Next
xTitleId = "KutoolsforExcel"
newName = Application.InputBox("Name", xTitleId, "", Type:=2)
For i = 1 To Application.Sheets.Count
    Application.Sheets(i).Name = newName & i
Next
End Sub

3.  点击 文档重命名多个工作表 4 按钮执行代码,然后在弹出对话框中输入所需的名称。请参见屏幕截图:

doc重命名工作表2

4. 点击 OK。 然后,您可以看到所有工作表都已重命名。

doc重命名工作表3

2. VBA代码通过活动工作簿的每个工作表中的特定单元格值重命名多个工作表

使用以下VBA代码,它将通过使用特定单元格的内容来重命名当前工作簿的所有工作表。 例如,您可以在整个工作簿的A1单元格中键入工作表名称,然后将工作表重命名为单元格值A1。

1.  请指定一个单元格以在每个工作表中包含工作表名称,然后在其中键入工作表名称。 在本示例中,我将在每个工作表的单元格A1中键入工作表名称。

2.  点击 开发商 > Visual Basic中和点击 插页 > 模块 ,在 Microsoft Visual Basic应用程序 Windows操作系统。

3.  请复制以下代码并将其粘贴到模块中。

VBA:通过特定的单元格内容重命名工作表

Sub RenameTabs()
'Updateby20140624
 For x = 1 To Sheets.Count
 If Worksheets(x).Range("A1").Value <> "" Then
 Sheets(x).Name = Worksheets(x).Range("A1").Value
 End If
 Next
 End Sub

4.  点击 文档重命名多个工作表 4 按钮执行代码。 所有工作表均根据A1的单元格内容重命名。

笔记:

  • 在上面的代码中, A1 是您要基于其重命名工作表的单元格内容,可以根据需要进行更改
  • 如果特定单元格没有内容,则不会重命名特定单元格的工作表。

演示:使用 Kutools for Excel 重命名多个工作表


Kutools for Excel:超过 300 个方便的工具触手可及! 立即开始 30 天免费试用,没有任何功能限制。 立即下载!
Comments (23)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Hi, I am trying to rename tabs but the rename function in the dropdown list is grey and I have no idea how to activte it. Please help.
Regards
John
This comment was minimized by the moderator on the site
Useless without kutools. What a waste of time.
This comment was minimized by the moderator on the site
i wants some requirments
1: i wants two or more blank sheets between two main sheets.

2: i want to copy one condent from sheet 1 to other sheets, at the same time the heading condet sheet name wil be chenged both sheets. that

sheet 01 heading is sheet 01. icopy the condent and paste it to other 1500 sheet at the same time i want to change the sheet name will be changed sheet 02, sheet 03 this orderly

3: i want to copy one condent from first sheet and i want to paste it some specific pages..
This comment was minimized by the moderator on the site
Good day,
Sorry can't help you with that yet. Welcome to post any question in our forum: https://www.extendoffice.com/forum.html to get more Excel support from out Excel professional or other Excel fans.
This comment was minimized by the moderator on the site
This is fab, I've been happily using '2. VBA code to rename multiple worksheets by specific cell value in each worksheet of the active workbook for months but now work have upgraded to Excel 2010 and it doesn't work anymore... can't find a similar solution online - any suggestions?
This comment was minimized by the moderator on the site
Thats great!!!, thank you very much for sharing vba codes. they are very useful
This comment was minimized by the moderator on the site
Thats great!!!, thank you very much for sharing vba codes. they are very useful
This comment was minimized by the moderator on the site
What if we want to have the numbers in descending order from 52 to 1?
This comment was minimized by the moderator on the site
I need to rename worksheets with data in cell Q5, however, multiple worksheets contain the same data in Q5. How can I tell Excel to rename those worksheets with the data in Q5 and just add something (like 1 or 2) after the name? I hope this makes sense.
This comment was minimized by the moderator on the site
I have tried to come up with something very similar, I have worksheet that has 2 columns and 119 rows. I need to take A1:B1 put them together and rename 3rd worksheet, next A2:B2, put them together and rename 4th worksheet, on until row 119. I have been hitting my head on the monitor trying to come up with easy way to do this. Any help would be much appreciated!
This comment was minimized by the moderator on the site
I have been looking for something very similar to these, however...I have sheet that has 2 columns and 119 rows. I need to combine A1:B1, start at the 3rd worksheet to rename the tab, next would be A2:B2, rename the 4th tab, so on and so forth. I have been beating my head against monitor and can't figure this one out...any help would be appreciate it.
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations