Funktioniert
Epfang:
Delphi-Quellcode:
procedure TForm1.IdUDPServer1UDPRead(Sender: TObject; AData: TBytes;
ABinding: TIdSocketHandle);
var
paketik : TUDPPacket;
begin
move(Adata[0], paketik, sizeof(TUDPPacket));
Senden:
Delphi-Quellcode:
procedure TForm1.UDPSendMyRecord(
ip :
string; SomeRecord: TUDPPacket);
var
dummy : Tbytes;
begin
setlength(dummy, sizeof(TUDPPacket));
move(SomeRecord, dummy[0], sizeof(SomeRecord));
form1.IdUDPClient1.Host :=
ip;
form1.IdUDPClient1.SendBuffer(dummy);
end;
Danke allen für die Hilfe...
))