巧用宏命令,完美实现一页A4纸打印多张高清照片或幻灯片_第1页
巧用宏命令,完美实现一页A4纸打印多张高清照片或幻灯片_第2页
巧用宏命令,完美实现一页A4纸打印多张高清照片或幻灯片_第3页
巧用宏命令,完美实现一页A4纸打印多张高清照片或幻灯片_第4页
巧用宏命令,完美实现一页A4纸打印多张高清照片或幻灯片_第5页
已阅读5页,还剩1页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、巧用宏命令,完美实现一页 A4 纸打印多张高清照片或幻灯片莘县一中 张仿刚工作中我们经常遇到这些情况:学籍库中 2000 多张照片,如何有序的打印在 A4 纸上,每张 36 张且把 学籍号有序的自动填充到照片下方?家庭外出游玩的照片如何方便的按规定的尺寸打印在 A4 像纸上?一 个 ppt 文件有 96 张幻灯片,如何清晰的在 A4 纸中一页打 8 张 ppt (甚至更多张)?本文就以实例解决上 述问题。首先我们需要在 word中安装自动排版”宏命令,方法如下:wordf工具宀宏宀录制新宏宀宏名macrol 改为自动排版”f确定f界面出现蓝色对话框,停止录制,然后wordf 工具f宏f选中宏自

2、动排版”f编辑,删除尾行的end sub”,然后在尾行复制粘贴下列内容,关闭Visual Basic编辑器,这样自动排版的宏命令就已经制作好了。【调整页边距及页眉页脚距,适用于A4 纸】With ActiveDocument.Styles(wdStyleNormal).FontIf .NameFarEast = .NameAscii Then .NameAscii = End If.NameFarEast = End With With ActiveDocument.PageSetup .LineNumbering.Active = False .Orientation = wdOrientP

3、ortrait .TopMargin = CentimetersToPoints(1.6) .BottomMargin = CentimetersToPoints(0.9) .LeftMargin = CentimetersToPoints(1.4) .RightMargin = CentimetersToPoints(1) .Gutter = CentimetersToPoints(0) .HeaderDistance = CentimetersToPoints(0.5) .FooterDistance = CentimetersToPoints(0.9) .PageWidth = Cent

4、imetersToPoints(21) .PageHeight = CentimetersToPoints(29.7) .FirstPageTray = wdPrinterDefaultBin .OtherPagesTray = wdPrinterDefaultBin .SectionStart = wdSectionNewPage .OddAndEvenPagesHeaderFooter = False .DifferentFirstPageHeaderFooter = False .VerticalAlignment = wdAlignVerticalTop .SuppressEndnot

5、es= False .MirrorMargins = False .TwoPagesOnOne = False .BookFoldPrinting = False .BookFoldRevPrinting = False .BookFoldPrintingSheets = 1 .GutterPos = wdGutterPosLeft .LayoutMode = wdLayoutModeLineGridEnd With【加页码,页脚居中处】Selection.Sections(1).Footers(1).PageNumbers.Add PageNumberAlignment:= _ wdAlig

6、nPageNumberCenter, FirstPage:=TrueIf ActiveWindow.View.SplitSpecial wdPaneNone ThenActiveWindow.Panes(2).CloseEnd IfIf ActiveWindow.ActivePane.View.Type = wdNormalView Or ActiveWindow. _ ActivePane.View.Type = wdOutlineView Then ActiveWindow.ActivePane.View.Type = wdPrintViewEnd If ActiveWindow.Acti

7、vePane.View.SeekView = wdSeekCurrentPageHeader If Selection.HeaderFooter.IsHeader = True ThenActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageFooter ElseActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeaderEnd IfIf ActiveWindow.ActivePane.View.Type = wdNormalView Or ActiveWindow. _

8、 ActivePane.View.Type = wdOutlineView ThenIf ActiveWindow.Panes.Count = 2 ThenActiveWindow.Panes(2).CloseEnd IfActiveWindow.View.SplitSpecial = wdPaneCurrentPageHeaderElseActiveWindow.View.SeekView = wdSeekCurrentPageHeader End If ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument ActiveWind

9、ow.ActivePane.VerticalPercentScrolled = 0【调整每张幻灯片的大小为高 184 宽 262,也许还有更佳的值,可自己尝试】Dim i As IntegerFor i = 1 To ActiveDocument.InlineShapes.CountActiveDocument.InlineShapes(i).Height = 184 ActiveDocument.InlineShapes(i).Width = 262Next i【给每张幻灯片加边框】Selection.HomeKey Unit:=wdStoryDim j As IntegerFor j =

10、1 To ActiveDocument.InlineShapes.CountSelection.MoveRight Unit:=wdCharacter, Count:=1, Extend:=wdExtendWith Selection.InlineShapes(1)With .Borders(wdBorderLeft) .LineStyle = wdLineStyleSingle .LineWidth = wdLineWidth050pt .Color = wdColorAutomaticEnd WithWith .Borders(wdBorderRight).LineStyle = wdLi

11、neStyleSingle.LineWidth = wdLineWidth050pt.Color = wdColorAutomaticEnd WithWith .Borders(wdBorderTop).LineStyle = wdLineStyleSingle.LineWidth = wdLineWidth050pt.Color = wdColorAutomaticEnd WithWith .Borders(wdBorderBottom).LineStyle = wdLineStyleSingle.LineWidth = wdLineWidth050pt.Color = wdColorAut

12、omaticEnd With.Borders.Shadow = FalseEnd WithWith Options.DefaultBorderLineStyle = wdLineStyleSingle .DefaultBorderLineWidth = wdLineWidth050pt .DefaultBorderColor = wdColorAutomaticEnd WithSelection.MoveRight Unit:=wdCharacter, Count:=1Next jEnd Sub2000 张的一样一、在一页 A4 纸上打印多张高清照片 以建立学籍为例,照片放在桌面新建文件夹内,

13、本例以 36 张照片为例, 可以一次全部导入,方法完全相同。第一步:修改宏文件。工具T宏T宏“自动排版”,改变照片宽度和高度,其他不变,文件呻 艇叩 视田皿 插人 褂式q 调试 运行如 工共吧 夕腹程序卽 国口血 艺助血If Sclecti cn. KedcrFoeter IsK-edcr = True TAcIl vAlfbudcv. A.cli vd-u1. Vlav. Sfi4id!.4R - a 4lurAitF:*Feia tai* El?eActLV4!rLiXic. A.cl3Vitinr. Sa4Ic7la - 出a首肚出urEnd IfIf Mtivdiiidg. hd 删V

14、iw. 1畀由-廿心|*11対Or也屯沖社怖皿叶.AcUvefm.e Viv.T7pe = wd&a 11 inteVi.tr TheaIf AeLLvft LTidov. P uias. Cciunl - 2 IhAaActivVaudimr. FvneiCZ) dci-xtEM IfAc t tveVandw. Vi w Spli tSpc-ca -il = vdF-wtCurTCDitF-idtetder EkaAc t icVandw. Vi w StckVae- = wdSt eKmre口tTifdfeier EwS IfActkVflmdw. AcliTtFrie. Viw.= w

15、eeflaLnDorm1闻号格式mor芒机Up|环1式.L,色些 v|左S挤20(03725172顼目帚号和占号A竽韩妁 审怪落俎制表位泣迓: 叵T4屋米 c2C103725WJCI2010S725C-311 201097260012ill东命尾&荡 与Heg.二.乱 n.町叠趋xx 1 X4EIF-C.pr!*+ *r v rt4f *睜呻if吳-古皤打萤的容初f 折1irit*JKfl 耳塞,N墓尊审;|.呻电膜IE量* r.sa e17- 0 弓 r- e-w. f *:TW E-!-*-siJr i土磕r rm举 內#匕H 暫!*;隹韭#壬比:ELM!空耐亀S-W4E44- AT?KU-二、在一页A4纸上打印8张ppt幻灯片常常需要将PPT的内容以讲义形式打印出来,但 PPT打 印设置里只支持一页纸上打印123,4,6,9页幻灯片几种形式, 而且格式几乎无法调整而且格式几乎无法调整。笔者尝试打 开ppt文件后,执行:文件打印对话框“打印内容” 选择“讲义”-“每页幻灯片数”选择9-预览结果很不理想, 幻灯片之间的间距过大,从而使得幻灯片内容太小且不清晰。 本法仍然采取宏命令进行操作。第一步:Powerpoint :文件另存为windows图元文件,如果PP

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论