Re: Attachment Problem

Giganews Newsgroups
Subject: Re: Attachment Problem
Posted by:  Remy Lebeau \(Indy Team\) (re…@lebeausoftware.org)
Date: Mon, 18 Oct 2010

"Tom Hahn" <tha…@hahntech.com> wrote in message
news:D67627CF99C2E340tha…@hahntech.com...

> I am upgrading a program from Delphi 7 / Indy 10.0.18 (I think)
<snip>
> I was using code to send an attachment which no longer compiles:

That code is for Indy 9, not Indy 10.  In Indy 10, TIdAttachment was changed
into an abstract base class for new descendant classes.  This is stated in
the Indy 10 documentation:

http://www.indyproject.org/docsite/html/ChangesObjectHierarchy.html

In this situation, use TIdAttachmentFile now:

TIdAttachmentFile.Create(Msg.MessageParts, UserSession.Attachment);

> How can I find out the version of Indy being used?

Right-click on any Indy component in the Form Designer.

--
Remy Lebeau (TeamB)

Replies

In response to

Attachment Problem posted by Tom Hahn on Sun, 17 Oct 2010