怎么把许多图片放到word文档中?
有许多图片文件,想把它们规律的排列到word中,然后打印出来,一张纸6个图。但是图太多了,一个一个贴太麻烦,有没有什么自动生成的方法呢?我需要生成的时候吧文件名也带上。我...
有许多图片文件,想把它们规律的排列到word中,然后打印出来,一张纸6个图。但是图太多了,一个一个贴太麻烦,有没有什么自动生成的方法呢?我需要生成的时候吧文件名也带上。
我现在的方法是把图片文件自动生成PPT,然后用文档的方式打印出来,一张纸6个是没有问题,但是没有图片名字了,混在一起分不出来。
有什么好办法吗? 展开
我现在的方法是把图片文件自动生成PPT,然后用文档的方式打印出来,一张纸6个是没有问题,但是没有图片名字了,混在一起分不出来。
有什么好办法吗? 展开
1个回答
2014-01-04
展开全部
1、acdsee可以打印缩略图,带文件路径的
2、也可以用如下的word宏
Sub 宏1()
'
'成都豺狼
'
pth = "C:\\My Pictures\\"
'读入文件的路径
fln = Dir(pth & "*.jpg")
'文件类型,没有其它文件,可以只用路径
wdth = ActiveDocument.PageSetup.PageWidth - ActiveDocument.PageSetup.LeftMargin - ActiveDocument.PageSetup.RightMargin
hght = ActiveDocument.PageSetup.PageHeight - ActiveDocument.PageSetup.TopMargin - ActiveDocument.PageSetup.BottomMargin
a = ActiveDocument.Paragraphs.LineSpacing
cnt = 0
Do While Len(fln) > 0
If cnt Mod 6 = 0 Then
Selection.MoveRight Unit:=wdCharacter, Count:=1
Selection.TypeParagraph
'Selection.InsertBreak Type:=wdPageBreak
ActiveDocument.Tables.Add Range:=Selection.Range, NumRows:=3, NumColumns:= _
4, DefaultTableBehavior:=wdWord9TableBehavior, AutoFitBehavior:= _
wdAutoFitFixed
Selection.Tables(ActiveDocument.Tables.Count).Select
Selection.SelectCell
Selection.ParagraphFormat.Alignment = wdAlignParagraphCenter
Selection.Cells.VerticalAlignment = wdCellAlignVerticalCenter
ActiveDocument.Tables(ActiveDocument.Tables.Count).AllowAutoFit = False
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(3).Select
Selection.Orientation = wdTextOrientationVertical
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(1).Select
Selection.Orientation = wdTextOrientationVertical
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(1).Width = wdth * 0.05
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(2).Width = wdth * 0.45
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(3).Width = wdth * 0.05
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(4).Width = wdth * 0.45
ActiveDocument.Tables(ActiveDocument.Tables.Count).Rows.Height = (hght - a - a) * 0.33
tablebili = ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(2).Width / ActiveDocument.Tables(ActiveDocument.Tables.Count).Rows.Height
End If
Selection.TypeText Text:=fln
Selection.MoveRight Unit:=wdCharacter, Count:=1
Selection.InlineShapes.AddPicture FileName:= _
pth & fln, LinkToFile:=False, _
SaveWithDocument:=True
cnt = ActiveDocument.InlineShapes.Count
bili = ActiveDocument.InlineShapes(cnt).Width / ActiveDocument.InlineShapes(cnt).Height
If tablebili > bili Then '控制图形按纵横比例显示,要拉伸就直接用行高列宽
ActiveDocument.InlineShapes(cnt).Height = ActiveDocument.Tables(ActiveDocument.Tables.Count).Rows.Height
ActiveDocument.InlineShapes(cnt).Width = ActiveDocument.InlineShapes(cnt).Height * bili
Else
ActiveDocument.InlineShapes(cnt).Width = ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(2).Width
ActiveDocument.InlineShapes(cnt).Height = ActiveDocument.InlineShapes(cnt).Width / bili
End If
Selection.MoveRight Unit:=wdCharacter, Count:=1
fln = Dir
DoEvents
Loop
End Sub
2、也可以用如下的word宏
Sub 宏1()
'
'成都豺狼
'
pth = "C:\\My Pictures\\"
'读入文件的路径
fln = Dir(pth & "*.jpg")
'文件类型,没有其它文件,可以只用路径
wdth = ActiveDocument.PageSetup.PageWidth - ActiveDocument.PageSetup.LeftMargin - ActiveDocument.PageSetup.RightMargin
hght = ActiveDocument.PageSetup.PageHeight - ActiveDocument.PageSetup.TopMargin - ActiveDocument.PageSetup.BottomMargin
a = ActiveDocument.Paragraphs.LineSpacing
cnt = 0
Do While Len(fln) > 0
If cnt Mod 6 = 0 Then
Selection.MoveRight Unit:=wdCharacter, Count:=1
Selection.TypeParagraph
'Selection.InsertBreak Type:=wdPageBreak
ActiveDocument.Tables.Add Range:=Selection.Range, NumRows:=3, NumColumns:= _
4, DefaultTableBehavior:=wdWord9TableBehavior, AutoFitBehavior:= _
wdAutoFitFixed
Selection.Tables(ActiveDocument.Tables.Count).Select
Selection.SelectCell
Selection.ParagraphFormat.Alignment = wdAlignParagraphCenter
Selection.Cells.VerticalAlignment = wdCellAlignVerticalCenter
ActiveDocument.Tables(ActiveDocument.Tables.Count).AllowAutoFit = False
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(3).Select
Selection.Orientation = wdTextOrientationVertical
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(1).Select
Selection.Orientation = wdTextOrientationVertical
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(1).Width = wdth * 0.05
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(2).Width = wdth * 0.45
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(3).Width = wdth * 0.05
ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(4).Width = wdth * 0.45
ActiveDocument.Tables(ActiveDocument.Tables.Count).Rows.Height = (hght - a - a) * 0.33
tablebili = ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(2).Width / ActiveDocument.Tables(ActiveDocument.Tables.Count).Rows.Height
End If
Selection.TypeText Text:=fln
Selection.MoveRight Unit:=wdCharacter, Count:=1
Selection.InlineShapes.AddPicture FileName:= _
pth & fln, LinkToFile:=False, _
SaveWithDocument:=True
cnt = ActiveDocument.InlineShapes.Count
bili = ActiveDocument.InlineShapes(cnt).Width / ActiveDocument.InlineShapes(cnt).Height
If tablebili > bili Then '控制图形按纵横比例显示,要拉伸就直接用行高列宽
ActiveDocument.InlineShapes(cnt).Height = ActiveDocument.Tables(ActiveDocument.Tables.Count).Rows.Height
ActiveDocument.InlineShapes(cnt).Width = ActiveDocument.InlineShapes(cnt).Height * bili
Else
ActiveDocument.InlineShapes(cnt).Width = ActiveDocument.Tables(ActiveDocument.Tables.Count).Columns(2).Width
ActiveDocument.InlineShapes(cnt).Height = ActiveDocument.InlineShapes(cnt).Width / bili
End If
Selection.MoveRight Unit:=wdCharacter, Count:=1
fln = Dir
DoEvents
Loop
End Sub
博思aippt
2024-07-20 广告
2024-07-20 广告
作为深圳市博思云创科技有限公司的工作人员,对于Word文档生成PPT的操作,我们有以下建议:1. 使用另存为功能:在Word中编辑完文档后,点击文件->另存为,选择PowerPoint演示文稿(*.pptx)格式,即可将文档内容转换为PPT...
点击进入详情页
本回答由博思aippt提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询
广告 您可能关注的内容 |