Article View: borland.public.cppbuilder.internet.socket
Article #708Re: How can I transfer the content of a list
From: Remy Lebeau (TeamB)
Date: Thu, 15 Nov 2007 21:57
Date: Thu, 15 Nov 2007 21:57
21 lines
1930 bytes
1930 bytes
"Bashar Termanini" <bashar-t@scs-net.org> wrote in message news:473cbd6a@newsgroups.borland.com... > I have a ListBox in the server and i want to transfer it to a > ListBox in the client by using TidTcpServer and idTcoClient TIdIOHandler has methods for reading/writing TStrings objects. Since TIdTCPServer is a threaded component, you will have to Synchronize with the main thread (such as with the TIdSync class) in order to safely access the ListBox. Copy its contents into a TStringList and then send it to the client. On the client side, if you are running TIdTCPClient in the main thread, then you can read the inbound data directly into the ListBox.Items property. Otherwise, read the data into a TStringList and then Synchronize with the main thread in order to update the ListBox. Gambit
Technical Details
Message-ID:
<473cc111$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!feeder1-2.proxad.net!proxad.net!feeder1-1.proxad.net!club-internet.fr!feedme-small.clubint.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<473b5fb5@newsgroups.borland.com> <473b7069$1@newsgroups.borland.com> <473cbd6a@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,3d483e6389458d8d X-Google-Attributes: gid11508e,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com> Newsgroups: borland.public.cppbuilder.internet.socket References: <473b5fb5@newsgroups.borland.com> <473b7069$1@newsgroups.borland.com> <473cbd6a@newsgroups.borland.com> Subject: Re: How can I transfer the content of a list Date: Thu, 15 Nov 2007 13:57:40 -0800 Lines: 23 Organization: Lebeau Software X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198 X-RFC2646: Format=Flowed; Response NNTP-Posting-Host: 207.178.157.90 Message-ID: <473cc111$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1195163921 207.178.157.90 (15 Nov 2007 13:58:41 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!feeder1-2.proxad.net!proxad.net!feeder1-1.proxad.net!club-internet.fr!feedme-small.clubint.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail