Edit

Frame.HeightRule property (Word)

Returns or sets a WdFrameSizeRule that represents the rule for determining the height of the specified frame. Read/write.

Syntax

expression. HeightRule

expression Required. A variable that represents a 'Frame' object.

Example

This example sets both the height and width of the first frame in the active document to exactly 1 inch.

If ActiveDocument.Frames.Count >= 1 Then 
 With ActiveDocument.Frames(1) 
 .HeightRule = wdFrameExact 
 .Height = InchesToPoints(1) 
 .WidthRule = wdFrameExact 
 .Width = InchesToPoints(1) 
 End With 
End If

See also

Frame Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.