 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
jose Guest
|
Posted: Mon Oct 20, 2003 4:52 pm Post subject: TidUDPServer trying to receive records |
|
|
I am using Indy 9 with Delphi 5 and working with TidUDPServer trying to send records.
At the UDPServerUDPRead(Sender: TObject; AData: TStream;
ABinding: TIdSocketHandle); procedure I have trouble reading the recorded info that I get from AData: TStream.
What I do is the following:
AData.WriteBuffer(MyRec,SizeOf(MyRec));
But nothing..
I would like to copy the info from the AData: TStream into a MyRec: (MyRecord = Packed Record ....)
Thank you for your time!!.
|
|
| Back to top |
|
 |
Martin James Guest
|
Posted: Mon Oct 20, 2003 5:32 pm Post subject: Re: TidUDPServer trying to receive records |
|
|
| Quote: | What I do is the following:
AData.WriteBuffer(MyRec,SizeOf(MyRec));
But nothing..
|
You have to read it. You are shoving extra records into the stream.
Adata.readBuffer(myRec,AData.size);
is my usual call.
Rgds,
Martin
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|