Board index » delphi » Embed Excel in Delphi

Embed Excel in Delphi

Hi All,

Is it possible to embed Excel within a Delphi TPanel object?  I'm
using D5 and Office 2000.  I'm opening the Excel application with
Excel_TLB.CoExcelApplication.  I'd like for Excel to appear to be a
part of my application.

Thanks,
Steve Harp

 

Re:Embed Excel in Delphi


Steve,

exlHnd := Excel_TLB.CoApplication.Create;

SetParent(exlHnd, YourPanel);

You will also need to do your cleanup before the Destroy event is called by
YourPanel
use

 procedure WMDestroy(var Message: TWMDestroy); message WM_DESTROY;

otherwise the parent handles have already been destroyed...

--
Cheers,
S. Adams

Quote
"Steve Harp" <NoS...@NoPlace.com> wrote in message

news:i8g0tt0f94el05ljbuvss4kit1oaiv2ff5@4ax.com...
Quote
> Hi All,

> Is it possible to embed Excel within a Delphi TPanel object?  I'm
> using D5 and Office 2000.  I'm opening the Excel application with
> Excel_TLB.CoExcelApplication.  I'd like for Excel to appear to be a
> part of my application.

> Thanks,
> Steve Harp

Other Threads