Discussion:
Border Margin
(too old to reply)
Ferass Elrayes
2008-03-13 15:25:04 UTC
Permalink
How can we programatically obtain the Page border margin (you can access it
from Word by selecting Page Layout->Page Borders. Under the Page Border tab
select Options.) I need the values under Margin Left, right ... etc.

Thanks in advance for your help.
Doug Robbins - Word MVP
2008-03-13 19:45:53 UTC
Permalink
With ActiveDocument.Sections(1).Borders
MsgBox "The distance from the bottom in pts is " & .DistanceFromBottom
MsgBox "The distance from the Left in pts is " & .DistanceFromLeft
MsgBox "The distance from the Right in pts is " & .DistanceFromRight
MsgBox "The distance from the Top in pts is " & .DistanceFromTop
End With
--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
Post by Ferass Elrayes
How can we programatically obtain the Page border margin (you can access it
from Word by selecting Page Layout->Page Borders. Under the Page Border tab
select Options.) I need the values under Margin Left, right ... etc.
Thanks in advance for your help.
Ferass Elrayes
2008-03-14 12:45:01 UTC
Permalink
Works well! Thanks!
Post by Doug Robbins - Word MVP
With ActiveDocument.Sections(1).Borders
MsgBox "The distance from the bottom in pts is " & .DistanceFromBottom
MsgBox "The distance from the Left in pts is " & .DistanceFromLeft
MsgBox "The distance from the Right in pts is " & .DistanceFromRight
MsgBox "The distance from the Top in pts is " & .DistanceFromTop
End With
--
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
Post by Ferass Elrayes
How can we programatically obtain the Page border margin (you can access it
from Word by selecting Page Layout->Page Borders. Under the Page Border tab
select Options.) I need the values under Margin Left, right ... etc.
Thanks in advance for your help.
Loading...