BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Previewing a word document inside my application

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi OLE Automation
View previous topic :: View next topic  
Author Message
Will1
Guest





PostPosted: Tue Jan 20, 2004 3:40 am    Post subject: Previewing a word document inside my application Reply with quote



Hi, my cuestion is how can I preview a word document, but inside of a
delphi form, thanks a lot



--- posted by geoForum on http://delphi.newswhat.com
Back to top
Mike Shkolnik
Guest





PostPosted: Tue Jan 20, 2004 5:47 am    Post subject: Re: Previewing a word document inside my application Reply with quote



Quote:
Hi, my cuestion is how can I preview a word document, but inside of a
delphi form, thanks a lot
Use TOLEContainer and load your doc-file there using

TOLEContainer.CreateObjectFromFile method...
--
With best regards, Mike Shkolnik
E-mail: [email]mshkolnik (AT) scalabium (DOT) com[/email]
WEB: http://www.scalabium.com



Back to top
Will1
Guest





PostPosted: Wed Jan 21, 2004 1:50 am    Post subject: Re: Previewing a word document inside my application Reply with quote



Can you gime me an example please?

[email]amarquez80itv (AT) yahoo (DOT) com[/email]



--- posted by geoForum on http://delphi.newswhat.com
Back to top
Warren Postma
Guest





PostPosted: Wed Jan 21, 2004 7:50 pm    Post subject: Re: Previewing a word document inside my application Reply with quote

Will1 wrote:

Quote:
Can you gime me an example please?

[email]amarquez80itv (AT) yahoo (DOT) com[/email]



--- posted by geoForum on http://delphi.newswhat.com

(1) Create new blank project.

(2) go to the System tab of your component palette. Click on the icon
that says OLE, now click on the Form1 window.

(3) Drop an OpenDialog on your form, and also add a Button or a Menu

(4) Double click on the button, or Menu item handler, and write this code:

if OpenDialog1.Execute then begin
OleContainer1.CreateObjectFromFile
( OpenDialog1.FileName,false);
OleContainer1.DoVerb(ovShow);
end;


Warren Postma

Back to top
Will1
Guest





PostPosted: Thu Jan 22, 2004 12:50 am    Post subject: Re: Previewing a word document inside my application Reply with quote

Quote:
Hi, my cuestion is how can I preview a word document, but inside of a
delphi form, thanks a lot
Use TOLEContainer and load your doc-file there using
TOLEContainer.CreateObjectFromFile method...
--
With best regards, Mike Shkolnik
E-mail: [email]mshkolnik (AT) scalabium (DOT) com[/email]
WEB: http://www.scalabium.com


Can you give me an example, please?



--- posted by geoForum on http://delphi.newswhat.com

Back to top
Will1
Guest





PostPosted: Thu Jan 22, 2004 12:51 am    Post subject: Re: Previewing a word document inside my application Reply with quote

Quote:
Hi, my cuestion is how can I preview a word document, but inside of a
delphi form, thanks a lot
can you give me an example?



--- posted by geoForum on http://delphi.newswhat.com

Back to top
Will1
Guest





PostPosted: Thu Jan 22, 2004 12:54 am    Post subject: Re: Previewing a word document inside my application Reply with quote

Can you give me and example please?



--- posted by geoForum on http://delphi.newswhat.com
Back to top
Mike Shkolnik
Guest





PostPosted: Thu Jan 22, 2004 5:44 am    Post subject: Re: Previewing a word document inside my application Reply with quote

Quote:
Can you give me and example please?
Yesterday in message from Warren Postma you see absolutelly correct answer.


Just drop TOLEContainer component on form and in run-time call the
CreateObjectFromFile method:
OleContainer1.CreateObjectFromFile(yourFileName, False);

There everything is clear...
--
With best regards, Mike Shkolnik
E-mail: [email]mshkolnik (AT) scalabium (DOT) com[/email]
WEB: http://www.scalabium.com



Back to top
Will1
Guest





PostPosted: Thu Jan 22, 2004 11:31 pm    Post subject: Re: Previewing a word document inside my application Reply with quote

Thanks a lot pal



--- posted by geoForum on http://delphi.newswhat.com
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi OLE Automation All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.