乔山办公网我们一直在努力
您的位置:乔山办公网 > excel表格制作 > 如何用word,excel制作书本的目录?-excel制作导航,excel 漂亮的导航页面

如何用word,excel制作书本的目录?-excel制作导航,excel 漂亮的导航页面

作者:乔山办公网日期:

返回目录:excel表格制作


、新建Excel工作簿,在工作表中依次输入文件夹内的Word文件名。

2、打开文件夹,按下shift键右键单击文件,找到复制为路径命令,并单击。

3、依次复制文件的路径到Excel工作簿内,和相应的文件名相对应。

4、在C列使用HYPERLINK函数创建链接,公式为:=HYPERLINK(B2,"打开"&A2)

5、公式解析:HYPERLINK函数是用来创建超链接的函数,第一参数是打开文件的路径,第二个参数的意思是超链接显示的名称。经过如此设置,就能为多个Word文件创建索引目录,即使不在同一个文件夹也适用于这个方法。
6、使用这个方法也是有效的提高效率,对文件的归纳整理很有帮助。

做目录只用word

一、你要先将相应的标题设置好大纲级别,操作方法如下:
选中标题文字,单击菜单“格式”“段落”,找到大纲级别,按目录层次分别设置好1、2、3、4级。
二、生成目录,操作方法如下:
在插入目录的位置单击,一般在文件末尾的新页上(因为你是新手,不建议用分节的方法操作。因为步骤太复杂),单击菜单“插入”“引用”“索引和目录”,单击“目录”选项卡,相应好要显示的大纲级别就可以了。
打开要创建目录的EXCEL文件--------Alt+F11---------插入--------模块--------把下面的代码拷贝到模块中e799bee5baa6e997aee7ad94e59b9ee7ad94364

Sub mulu()
On Error GoTo Tuichu
Dim i As Integer
Dim ShtCount As Integer
Dim SelectionCell As Range

ShtCount = Worksheets.Count
If ShtCount = 0 Or ShtCount = 1 Then Exit Sub
Application.ScreenUpdating = False
For i = 1 To ShtCount
If Sheets(i).Name = "目录" Then
Sheets("目录").Move Before:=Sheets(1)
End If
Next i
If Sheets(1).Name <> "目录" Then
ShtCount = ShtCount + 1
Sheets(1).Select
Sheets.Add
Sheets(1).Name = "目录"
End If
Sheets("目录").Select
Columns("B:B").Delete Shift:=xlToLeft
Application.StatusBar = "正在生成目录…………请等待!"
For i = 2 To ShtCount
ActiveSheet.Hyperlinks.Add Anchor:=Worksheets("目录").Cells(i, 2), Address:="", SubAddress:= _
Sheets(i).Name & "!R1C1", TextToDisplay:=Sheets(i).Name
Next
Sheets("目录").Select
Columns("B:B").AutoFit
Cells(1, 2) = "目录"
Set SelectionCell = Worksheets("目录").Range("B1")
With SelectionCell
.HorizontalAlignment = xlDistributed
.VerticalAlignment = xlCenter
.AddIndent = True
.Font.Bold = True
.Interior.ColorIndex = 34
End With
Application.StatusBar = False
Application.ScreenUpdating = True
Tuichu:
End Sub

关闭BASIA的界面

在你要插入的电子表格里按ALT+F8

选好你刚才写的模块mulu

点执行

--------OK

打开要创建目录e79fa5e98193e4b893e5b19e332的EXCEL文件--------Alt+F11---------插入--------模块--------把下面的代码拷贝到模块中

Sub mulu()
On Error GoTo Tuichu
Dim i As Integer
Dim ShtCount As Integer
Dim SelectionCell As Range

ShtCount = Worksheets.Count
If ShtCount = 0 Or ShtCount = 1 Then Exit Sub
Application.ScreenUpdating = False
For i = 1 To ShtCount
If Sheets(i).Name = "目录" Then
Sheets("目录").Move Before:=Sheets(1)
End If
Next i
If Sheets(1).Name <> "目录" Then
ShtCount = ShtCount + 1
Sheets(1).Select
Sheets.Add
Sheets(1).Name = "目录"
End If
Sheets("目录").Select
Columns("B:B").Delete Shift:=xlToLeft
Application.StatusBar = "正在生成目录…………请等待!"
For i = 2 To ShtCount
ActiveSheet.Hyperlinks.Add Anchor:=Worksheets("目录").Cells(i, 2), Address:="", SubAddress:= _
Sheets(i).Name & "!R1C1", TextToDisplay:=Sheets(i).Name
Next
Sheets("目录").Select
Columns("B:B").AutoFit
Cells(1, 2) = "目录"
Set SelectionCell = Worksheets("目录").Range("B1")
With SelectionCell
.HorizontalAlignment = xlDistributed
.VerticalAlignment = xlCenter
.AddIndent = True
.Font.Bold = True
.Interior.ColorIndex = 34
End With
Application.StatusBar = False
Application.ScreenUpdating = True
Tuichu:
End Sub

关闭BASIA的界面

在你要插入的电子表格里按ALT+F8

选好你刚才写的模块mulu

点执行

--------OK

相关阅读

关键词不能为空
极力推荐

ppt怎么做_excel表格制作_office365_word文档_365办公网