Set font in Word from 4GL

BrianSmith

New Member
Hi. I can open a document using 'CREATE "word.application" chWord' from within my Progress program, but how do I set the font for the whole document from within the Progress application? I've tried this unsuccessfully:

chWord:Selection:WholeStory(). /* to try to select the whole document */
chWord:Selection:Font:Size = "8.0" . /* to set the font for the document */

I got the above commans from a Word macro, but they don't work.

Also tried:

chWord:Size = "8.0" from the COM object viewer, but no luck.

How can I do this?

Thanks, Brian
 

Casper

ProgressTalk.com Moderator
Staff member
If my memory serves me well, size must be an integer. Did you try:
Code:
chWord:Selection:Font:Size = 8.

HTH,

Casper.
 

M.Fondacci

New Member
Easier way is to download the 'automation.i' include file at www.4gl.fr

It includes all basic functions and more within an inlcude file.



Hi. I can open a document using 'CREATE "word.application" chWord' from within my Progress program, but how do I set the font for the whole document from within the Progress application? I've tried this unsuccessfully:

chWord:Selection:WholeStory(). /* to try to select the whole document */
chWord:Selection:Font:Size = "8.0" . /* to set the font for the document */

I got the above commans from a Word macro, but they don't work.

Also tried:

chWord:Size = "8.0" from the COM object viewer, but no luck.

How can I do this?

Thanks, Brian
 
Top