How to set the default size for all the images in the document?

  • Thread starter Thread starter Mamta
  • Start date Start date
M

Mamta

For any particular image in the document we can set it size by right click on
the image -> click on Format Picture-->click on Size tab (where we can
increase or decrease the size height and width). But my question we have to
set the size for every image which we add. Is there any option from where we
can set the default size for every image
 
You could use a borderless table cell, and insert the image into this,
usually the image will resize to fit that cell, but not always - I think it
depends on the file format of the image but not sure.

Many have asked this question on this forum, instead of this way round I use
to macro to resize all images that are present in the document.
If the Images are InLineWithText then the following macro will change all in
one click. Be aware that embedded files displayed as icons are considered
InLineWithText graphics, so these will be resized.
I got the macro initially from an MVP on this site, cannot remember who, and
have augmented it to its present state.

Sub ResizePictureWidth()
Dim inshpPower As InlineShape
Dim sngOldWidth As Single
Const sngNewWidth As Single = 13.5
With ActiveDocument
If .InlineShapes.Count 0 Then
For Each inshpPower In .InlineShapes
With inshpPower
sngOldWidth = .Width
.Width = CentimetersToPoints(sngNewWidth)
.Height = CentimetersToPoints(((.Height * sngNewWidth) /
sngOldWidth))
End With
Next
Else
MsgBox "There are no shapes in this document.", _
vbExclamation, "Cancelled"
End If
End With
End Sub
This macro is set for width of 13.5cm, so you may need to change this for
your needs and units.
See http://word.mvps.org/FAQs/MacrosVBA/CreateAMacro.htm for help with macros.
Beware, this macro will hit anything that is InLineWithText and this
includes embedded files, so it will resize the icon to 13.5cm ;-)
If the images are floating (i.e. not set with the InLineWithText) the you
can use the Select Multiple Objects (the icon is found on the Drawing Toolbar
under Customize).
Beware this may select objects you don't want to change, so tread carefully
- maybe work on a copy of the document.
 
Back
Top