- word文档教程:Word如何替换内容?Word替换文本内容的方法
- word制作简历教程:Word换行时英文单词不分开的设置方法
- word制作表格教程基础入门:Word2007给文档添加脚注信息
- word排版教程:在Word2010中查找和替换字符格式
在我们使用Word编辑时会插入大量的图片文件,word教程视频全集自学,当然这些图片大小一般是不一致的,通常插入到文档后都需要手动调整,如果说这些图片要调整统一大小,如何理解批量的调整大小呢?
1、打开插入图片的文档,点击切换到“视图”标签,点击“宏”-查看宏
2、在宏设置对话框,给这个宏起个名字,word教程零基础教程,然后点击右侧的“创建”按钮
3、打开VBA编辑器,用找到的代码粘贴替换默认的代码:
1 2 3 4 5 6 7 8
Sub SetPicSize() '设置图片大小 Dim n '图片个数 On Error Resume Next '忽略错误 For n = 1 To ActiveDocument.InlineShapes.Count 'InlineShapes 类型 图片 ActiveDocument.InlineShapes(n).Height = 24 * 28.35 '设置图片高度为 24cm (1cm等于28.35px) ActiveDocument.InlineShapes(n).Width = 14 * 28.35 '设置图片宽度 14cm Next n End Sub
4、复制好代码,点击工具栏的运行按钮▶(右三角)
5、跳出宏对话框,选择这个宏,word制作表格教程基础入门,点击“运行”按钮
6、关闭VBA编辑器,可以看到图片已经全部变为代码里设置的大小
上一篇:word学习全套教程:word 图片怎么批量调整大小 下一篇:word表格教程:word 字间距突然变大怎么解决 郑重声明:本文版权归原作者所有,转载文章仅为传播更多信息之目的,如作者信息标记有误,请第一时间联系我们修改或删除,多谢。