文档库 最新最全的文档下载
当前位置:文档库 › 图片批量处理宏

图片批量处理宏

Sub AdjustPicWidthAndHeight()
'
'Sub FormatPics()
Dim iSha As InlineShape
For Each iSha In ActiveDocument.InlineShapes
If iSha.Type = wdInlineShapePicture Then
iSha.LockAspectRatio = msoFalse '不锁定纵横比
iSha.Width = CentimetersToPoints(6.46) '宽5CM
iSha.Height = CentimetersToPoints(6.28) '高5CM
End If
Next
End Sub
Public Sub 改变图片尺寸()
Dim i As Shape
For Each i In ActiveSheet.Shapes
i.Select
Selection.ShapeRange.LockAspectRatio = msoFalse
Selection.ShapeRange.Height = 5 '' 高度 [尺寸自己可变更]
Selection.ShapeRange.Width = 5 '' 宽度 [尺寸自己可变更]
Selection.ShapeRange.Rotation = 0# ‘’旋转角度
Next
End Sub

相关文档
相关文档 最新文档