Article View: borland.public.cppbuilder.internet.socket
Article #5252Re: How can I send a TBitmap from Client application to Server application
From: Byanex
Date: Mon, 27 Sep 2004 19:47
Date: Mon, 27 Sep 2004 19:47
20 lines
1585 bytes
1585 bytes
Mark Jacobs
Thank you very much, that code realy works.
One more thing, the server code below presents some acces violation errors code when run with "delete" line, any one know why???
void __fastcall TForm1::Button1Click(TObject *Sender)
{
TMemoryStream* SendPms = new TMemoryStream();
Image1->Picture->Bitmap->SaveToStream(SendPms);
SendPms->Position=0;
ServerSocket1->Socket->Connections[0]->SendStream(SendPms);
delete SendPms; // <<-- This line
}
Without the delete line the code runs fine, any problem if just take out this line???
Best regards
Byanex
Technical Details
Message-ID:
<41586e5b$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!in.100proofnews.com!in.100proofnews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<407e54f8$1@newsgroups.borland.com> <407e66c5@newsgroups.borland.com> <407ec9c7@newsgroups.borland.com> <415080c1$1@newsgroups.borland.com> <415087be$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,b60555b8e5a57a55 X-Google-Attributes: gid11508e,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Byanex" <chikui@bol.com.br> Sender: "Byanex" <chikui@bol.com.br> Reply-To: "Byanex" <chikui@bol.com.br> Subject: Re: How can I send a TBitmap from Client application to Server application Newsgroups: borland.public.cppbuilder.internet.socket X-User-Info: 200.146.156.8 References: <407e54f8$1@newsgroups.borland.com> <407e66c5@newsgroups.borland.com> <407ec9c7@newsgroups.borland.com> <415080c1$1@newsgroups.borland.com> <415087be$1@newsgroups.borland.com> NNTP-Posting-Host: 207.105.83.66 Message-ID: <41586e5b$1@newsgroups.borland.com> Date: 27 Sep 2004 12:47:39 -0700 X-Trace: newsgroups.borland.com 1096314459 207.105.83.66 (27 Sep 2004 12:47:39 -0700) Lines: 22 Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!in.100proofnews.com!in.100proofnews.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail