Aligning a paragraph

J

James Wagner

Hi all

I use VB6 to create a word document.
I have a template with docvariables.

Set wField = WordDoc.Fields(WordDoc.Variables("strReportDate").Index)
Set wRange = wField.Code
If CBool(gclsProgramSetup.RTLLanguage) Then
wRange.ParagraphFormat.Alignment = 0
Else
wRange.ParagraphFormat.Alignment = 2
End If

This is the code I use to align the document text.

My problem is that when paragraph x is being aligned , paragraph y forgets
its alignment that was set before.

What should I do between these two alignments (x and y)?
Should I update the fields between each paragraph alignment ?
(e.g. Call WordDoc.Fields.Update)


TIA
Guy
 

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