General information
Category:
COM/DCOM and OLE Automation
I am trying to create a word OLE automation to copy the content of a memofield to a word document, then justify the text and save it in word. I am able to do everything but justify the text. This if the following code I am using, but it bombs on the justify command.
oWord=CREATEOBJECT("Word.Application")
oWord.WindowState=2
oWord.Visible = .F.
cSce="table.memo" ***memo field***
cmemo=EVAL(cSce)
_CLIPTEXT=""
_CLIPTEXT=cmemo oWord.Documents.Add.Content.Paste
oword.Selection.WholeStory
oword.Selection.ParagraphFormat.Alignment.wdAlignParagraphJustify
I've tried to record the macro, but I can't convert this code correctly.
Any Ideas..
TIA
Rob
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only