Centering text

D

Dean

Recently when centering text it centers the entire document, not just the
line I designated to center text on. I have to click on the undo button to
restore the rest of the document to what it was prior to my selection to
center a line of text. Somehow I did something to cause this because it
never worked like that before. Also, I have notice that at times when I do
a ctrl B to highlight text it does the same thing, highlights all of the
text in the document and when I click on undo the rest of the document is
restored to its original unhighlighted appearance. I run Word 2000.

Thanks for your help,
Dean
 
D

Dave Lett

Hi Dean,

Can you provide a snippet of code that centers all the text in your
document. Also, I assume that you only want a paragraph (the current one as
defined by the blinking insertion point) to be centered. If so, then you can
probably get away with the following:

Selection.Paragraphs(1).Alignment = wdAlignParagraphCenter

HTH
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top