Board index » delphi » How to save the changes made in a word document placed in OLE container/

How to save the changes made in a word document placed in OLE container/


2007-06-14 01:35:58 PM
delphi246
 Could you please solve my problem that includes how to save the changes
to the word document which is placed in an ole container? I also want not
to display the toolbar menu ?
Thanks in advance.....
--- posted by geoForum on delphi.newswhat.com
 
 

Re:How to save the changes made in a word document placed in OLE container/

<<Bhaskar:
I also want not to display the toolbar menu ?
Quote
>
You should probably consider using a TWebBrowser to
show the document, rather than a TOleContainer. But
you can hide the toolbars like this:
var
Bar, Word: OleVariant;
i: integer;
begin
Word := OleContainer1.OleObject.Application;
for i := 1 to Word.CommandBars.Count do
begin
Bar := Word.CommandBars[i];
if Bar.Visible then
{ store the information about which bars were
visible somewhere, so you can set Word back
to normal when you've finished!
... }
if (VarToStr(Bar.Name) <>'Menu Bar') then
begin
Memo1.Lines.Add(Bar.Name);
Bar.Visible := False;
end;
end;
--
Deborah Pate (TeamB) delphi-jedi.org
TeamB don't see posts sent via Google or ISPs
Use the real Borland server: newsgroups.borland.com
www.borland.com/newsgroups/genl_faqs.html