Author: Jonas Bilinkevicius
I want to run MS Word by using TOleContainer but I don't want to use the Insert
Object dialog. How can I do that?
Answer:
1 {Creating a new Word document in an Olecontainer}2 OleContainer1.CreateObject('Word.Document', False);
3 OleContainer1.DoVerb(ovShow);
4 5 {Loading an existing document in an Olecontainer}6 OleContainer1.CreateObjectFromFile('C:\Docs\Doc1.doc', False);
7 OleContainer1.DoVerb(ovShow);