Home Topics word How to batch resize word pictures

How to batch resize word pictures

Jun 22, 2019 pm 02:49 PM

How to batch resize word pictures

When we use Word to edit, we will insert a large number of picture files. Of course, the sizes of these pictures are generally inconsistent. Usually they need to be adjusted manually after being inserted into the document. If these pictures need to be adjusted Uniform size, how to understand batch resizing?

1. Open the document with the picture inserted, click to switch to the "View" tab, click "Macros" - View Macros

How to batch resize word pictures

2. In the macro settings dialog box, give this macro a name, and then click the "Create" button on the right

How to batch resize word pictures

3. Open the VBA editor and paste the found code to replace the default code:

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
Copy after login

How to batch resize word pictures

4. Copy the code and click the run button on the toolbar ▶ (right triangle)

How to batch resize word pictures

##5. Jump out of the macro dialog box, select this macro, and click the "Run" button

How to batch resize word pictures

6. Close the VBA editor and you can see that the pictures have all changed to the size set in the code

How to batch resize word pictures

For more technical articles related to Word, please visit the

Word Tutorial column to learn!

The above is the detailed content of How to batch resize word pictures. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)