Board index » delphi » Indy 8.1 POP3 and temp files

Indy 8.1 POP3 and temp files

Hi!

Why temporary file in TEMP directory is exist
after receiving mail with attachment.

How automatically delete them?

Micle.

 

Re:Indy 8.1 POP3 and temp files


mi...@netlab.ru (Micle) wrote in <3b305862_2@dnews>:

Quote
>Hi!

>Why temporary file in TEMP directory is exist
>after receiving mail with attachment.

>How automatically delete them?

Just delete them when you exit your application.

Re:Indy 8.1 POP3 and temp files


"Hadi Hariri - Team Indy" <hadi...@pbe.com> wrote in message
news:3b305f1f_2@dnews...

Quote
> mi...@netlab.ru (Micle) wrote in <3b305862_2@dnews>:

> >Hi!

> >Why temporary file in TEMP directory is exist
> >after receiving mail with attachment.

> >How automatically delete them?

> Just delete them when you exit your application.

Hi!

Certainly, I can delete them itself on POP3 disconnect,
but why Indy does not do it?

Micle

Quote

Re:Indy 8.1 POP3 and temp files


On 20 Jun 2001 01:30:23 -0700, hadi...@pbe.com (Hadi Hariri

Quote
- Team Indy) wrote:
>mi...@netlab.ru (Micle) wrote in <3b305862_2@dnews>:

>>Hi!

>>Why temporary file in TEMP directory is exist
>>after receiving mail with attachment.

>>How automatically delete them?

>Just delete them when you exit your application.

How are you supposed to do this when
you don't know the name of the file?

Otto Porter

Re:Indy 8.1 POP3 and temp files


Hi!

 procedure DeleteIndyTmpFiles(APath: string);
  var
   F: TSearchRec;
  const
   AMask = 'Ind*.tmp';
  begin
    if FindFirst(APath + AMask, 0, F) = 0 then
    begin
   DeleteFile(APath + F.Name);
      while FindNext(F) = 0 do
       DeleteFile(APath + F.Name);
      FindClose(F);
    end;
  end;

Micle.

Quote
"Otto Porter" <f...@xmission.com> wrote in message

news:4du2jt0uscnqsjeiqi2du7j6ajq2cjagrk@4ax.com...
Quote
> On 20 Jun 2001 01:30:23 -0700, hadi...@pbe.com (Hadi Hariri
> - Team Indy) wrote:

> >mi...@netlab.ru (Micle) wrote in <3b305862_2@dnews>:

> >>Hi!

> >>Why temporary file in TEMP directory is exist
> >>after receiving mail with attachment.

> >>How automatically delete them?

> >Just delete them when you exit your application.

> How are you supposed to do this when
> you don't know the name of the file?

> Otto Porter

Re:Indy 8.1 POP3 and temp files


On Thu, 21 Jun 2001 13:53:25 +0400, "Micle"

Quote
<mi...@netlab.ru> wrote:
>Hi!

> procedure DeleteIndyTmpFiles(APath: string);
>  var
>   F: TSearchRec;
>  const
>   AMask = 'Ind*.tmp';
>  begin
>    if FindFirst(APath + AMask, 0, F) = 0 then
>    begin
>   DeleteFile(APath + F.Name);
>      while FindNext(F) = 0 do
>       DeleteFile(APath + F.Name);
>      FindClose(F);
>    end;
>  end;

>Micle.

Thanks for the handy proc.

Otto Porter

Other Threads