Thanks for the reply,

I have managed to fudge a solution by first saving the the picture to a temp 
file and then using a filestream to copy the image into the compound (ActiveX) 
document. I was after a more elegant/efficient method.

Paul

Any system or problem, however complicated, if looked at in exactly the right 
way, will become even more complicated. 

----- Original Message -----
From: "Mauro Russo" <[EMAIL PROTECTED]>
To: [email protected]
Subject: Re: [delphi-en] Saving a TImage Picture to a File
Date: Wed, 30 Mar 2005 11:48:35 +0200

> 
> 
> try Picture.SaveToFile
> 
> ----- Original Message -----
> From: "Paul Bennett" <[EMAIL PROTECTED]>
> To: <[email protected]>
> Sent: Wednesday, March 30, 2005 11:29 AM
> Subject: [delphi-en] Saving a TImage Picture to a File
> 
> 
> >
> >
> > Can anyone help with this??
> >
> > The application I am currently working on, basically an order processing
> application, obtains a WMF image from an access database (no problem there).
> This image, together with other (text) information is to be sent to a
> Compound Document (basically they want to keep seperate the actual orders
> from the base data they are produced from).
> >
> > I am trying to save the image data using the code below:
> >
> >   Stream := Store.CreateStream('Graphic', MY_STGM_CREATE);
> >   fGraphic.Picture.Graphic.SaveToStream(Stream);
> >   Stream.Free;
> >
> > This appears to be working correctly, i.e. when I look in the file there
> is data in the 'graphics' stream. However when I attempt to retrieve the
> image, using
> >
> >   Stream := Store.OpenStream('Graphic', MY_STGM_OPEN);
> >   fGraphic.Picture.Graphic.LoadFromStream(Stream);
> >   Stream.Free;
> >
> > The graphic fails to display(at all). I do not get any exceptions during
> either the save or load process.
> >
> > Any ideas anyone???
> >
> >
> > TIA
> >
> > Paul Bennett
> > Experience is something you don't get until just after you need it.
> >
> > --
> > _____________________________________________________________
> > Web-based SMS services available at http://www.operamail.com.
> > >From your mailbox to local or overseas cell phones.
> >
> > Powered by Outblaze
> >
> >
> > -----------------------------------------------------
> > Home page: http://groups.yahoo.com/group/delphi-en/
> > To unsubscribe: [EMAIL PROTECTED]
> > Yahoo! Groups Links
> >
> >
> >
> >
> >
> >
> >
> >
> 
> 
> 
> -----------------------------------------------------
> Home page: http://groups.yahoo.com/group/delphi-en/
> To unsubscribe: [EMAIL PROTECTED]
> Yahoo! Groups Links
> 
> 
> 
> 

-- 
_____________________________________________________________
Web-based SMS services available at http://www.operamail.com.
>From your mailbox to local or overseas cell phones.

Powered by Outblaze


-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/delphi-en/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to