Re: How to save complete message into string/double headers

Giganews Newsgroups
Subject: Re: How to save complete message into string/double headers
Posted by:  Sabine Dinis Blochberger (no.spam@here.invalid)
Date: Wed, 06 Oct 2004

Sabine Dinis Blochberger wrote:

> Using Delphi 7 enterprise with Indy 9 (snapshot from 14th of Sept.
> 2004).
>
> I want to save the whole message for saveguard into a string (which then
> goes into a memo field in a database). The following code gives me that,
> *but* the header appears twice in a row.
>
>  // get raw message
>  stream := TStringStream.Create('');
>  try
>    Msg.SaveToStream (stream);
>    stream.Position := 0; // go to start
>    rawStr := stream.DataString; // get data
>  finally
>    FreeAndNil (stream);
>  end;
>
Calling Msg.Clear was a nessecity earlier on (I had Pop3.RetrieveHeader
for checking our spamlist, then I would call Pop3.Retrieve, leaving me
with a Msg with two headers).

Thanks for looking ;)

--
Dipl. Inform. Sabine Dinis Blochberger (FH)
Op3racional
s.blochberger  @  op3racional.de

Replies

None

In response to

How to save complete message into string/double headers posted by Sabine Dinis Blochberger on Wed, 15 Sep 2004