Hallo!
Ich hab in einem Record ein Array liegen! Wenn ich später auf das Array
zugreifen will erscheint eine Fehlermeldung (Zugriffsverletzung).
Einzelheiten poste ich hier jetzt mal:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35:
| type TCommBlock = record // the Communication Block used in both parts (Server+Client) Command, MyUserName, // the sender of the message MyComputerName, // Name of the sender IP, Msg, // the message itself ReceiverName: string[100]; // name of receiver DatumZeit: TDateTime; // Zeit der aktuellsten HostListe ClientList: array [1..2] of TStringList; end; var HostBlock: TCommBlock; implementation procedure TfrmNetViewer.UpdateClientList(); var i: integer; ListItem: TListItem; HostBlockt: TCommBlock; begin for i := 0 to RemoteListe.Items.Count-1 do begin ListItem := RemoteListe.Items.Item[i]; HostBlock.ClientList[1].Add(ListItem.Caption); HostBlock.ClientList[2].Add(ListItem.SubItems.CommaText); end; end; |
Warum gibt er mit an der Stelle
"HostBlock.ClientList[1].Add(ListItem.Caption);" eine Fehlermeldung?
Kann mir da jemand helfen?