Kbase P20445: ACTIVEX - How to insert data into a MS Word document
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  5/17/2010 |
|
Status: Verified
GOAL:
ACTIVEX - How to insert data into a MS Word document
GOAL:
Example of writing records into MS Word
FACT(s) (Environment):
OpenEdge 10.x
Progress 9.x
Windows
FIX:
DEFINE VARIABLE chWordApplication AS COM-HANDLE NO-UNDO.
CREATE "Word.application" chWordApplication.
chWordApplication:VISIBLE=TRUE.
chWordApplication:Documents:ADD().
FOR EACH customer WHERE custnum < 10.
chWordApplication:Selection:typetext(customer.NAME).
chWordApplication:Selecyion:typetext(" ").
chWordApplication:Selection:typetext(customer.custnum).
chWordApplication:selection:TypeParagraph.
END.
chWordApplication:Quit().
RELEASE OBJECT chWordApplication.