Re: attach file to email

Giganews Newsgroups
Subject: Re: attach file to email
Posted by:  Remy Lebeau (Indy Team) (no.spam@no.spam.com)
Date: Fri, 24 Nov 2006

"Don" <dngolsopcak…@comcast.net> wrote in message
news:5D56B097C110E340dngolsopcak…@comcast.net...

> This is what I have tried:

That is not correct.  You need to use the 'new' operator instead:

    void __fastcall TfrmMessageEditor::btnAttachmentClick(TObject *Sender)
    {
        if( OpenDialog1->Execute )
        {
            new TIdAttachment(IdMsgSend->MessageParts,
OpenDialog1->FileName);
            // ResetAttachmentListView();
        }
    }

Gambit

Replies

None

In response to

attach file to email posted by Don on Fri, 24 Nov 2006