经 守柔版主的多番指教,完整的代码如下: Sub 设置A4页面() ' Dim myShape As Variant Application.ScreenUpdating = False With ActiveDocument.PageSetup .PageWidth = CentimetersToPoints(21) .PageHeight = CentimetersToPoints(29.7) End With Dim i As Frame With ActiveDocument For Each myShape In .Shapes With myShape .ScaleHeight 1, True .ScaleWidth 1, True .Left = wdShapeCenter End With Next For Each myShape In .InlineShapes myShape.Select Set myShape = .InlineShapes(1).ConvertToShape With myShape .ScaleHeight 1, True, msoScaleFromMiddle .ScaleWidth 1, True, msoScaleFromMiddle .Left = wdShapeCenter End With Next End With For Each i In Me.Frames i.RelativeHorizontalPosition = wdRelativeHorizontalPositionMargin i.HorizontalPosition = Word.CentimetersToPoints(2) i.RelativeVerticalPosition = wdRelativeVerticalPositionMargin ' i.VerticalPosition = Word.CentimetersToPoints(2) Next Application.ScreenUpdating = True |