RE: Center text in current page by gordon(dot)bentleymix(at)gmail(dot)com>
gordon(dot)bentleymix(at)gmail(dot)com>
Wed Apr 09 19:11:05 PDT 2008
It depends on if you want to centre the text horizonally or vertically.
To centre horizontally, just set the Alignment property of the title
paragraphs to wdAlignParagraphCenter.
To centre vertically, insert a section break after the title and then set
the vertical alignment of the section to centred using something like this:
ActiveDocument.Sections(1).PageSetup.VerticalAlignment=wdAlignVerticalCenter
Of course this is greatly simplified, but at least it gives you an idea of
what objects and properties to look at.
--
Cheers!
The Kiwi Koder
Please note: Uninvited email contact will be marked as SPAM and ignored -
unless you want to hire me. ;-)
"juan" wrote:
> Hello:
> I have generated a Word document from code with Visual Basic 2005. I'm using
> Word 2003. I want to center a title in the first page (two lines), but only
> in this page. I have tried a few method but they didn't work properly. Any
> idea?
> Thanks.
>