🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #4166

Problem with TIdAttachment

#4166
From: depresz
Date: Sat, 26 Mar 2005 18:29
27 lines
1914 bytes
Hi,
I installed Indy, I create TIdAttachment component, next I reinstall 
CPP. When I install next time, I didn't have TIdAttachment. I'm used comand:


> for(int x = 0; x < FormaGlowna->IdMessage1->MessageParts->Count; x++)
> {
> 	if(TIdText *text = dynamic_cast<TIdText*>(FormaGlowna->IdMessage1->MessageParts->Items[x]))
>       {
>       	int i = i;
>               // *text only NULLs; MessageParts->Count =1; should be jpeg image in there ?!
>       }
>       else if(TIdAttachment *attachment = dynamic_cast<TIdAttachment*>(FormaGlowna->IdMessage1->MessageParts->Items[x]))
>       {
> 
>               FormaGlowna->ListBox1->Clear();
>               FormaGlowna->Label63->Caption = "Tak";
>               FormaGlowna->ListBox1->Items->Add(attachment->FileName);
>               FormaGlowna->Label74->Visible = true;
>       }
> }

I have special problem with:

> FormaGlowna->ListBox1->Items->Add(attachment->FileName);

I'm using indy 9 reinstall to 10
Technical Details
Message-ID: <4245aa0f@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!newshub.sdsu.edu!logbridge.uoregon.edu!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,533b4ee19c37217,start
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
Date: Sat, 26 Mar 2005 19:29:55 +0100
From: depresz <depresz@piotrkow.net.pl>
User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206)
X-Accept-Language: pl, en-us, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.internet.socket
Subject: Problem with TIdAttachment
Content-Type: text/plain; charset=ISO-8859-2; format=flowed
Content-Transfer-Encoding: 7bit
X-Antivirus: avast! (VPS 0512-2, 2005-03-26), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: 195.136.149.45
Message-ID: <4245aa0f@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1111861775 195.136.149.45 (26 Mar 2005 10:29:35 -0800)
Lines: 27
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!newshub.sdsu.edu!logbridge.uoregon.edu!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail