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: 36: 37: 38: 39: 40:
| program Project1;
{$APPTYPE CONSOLE}
uses SysUtils,Windows,Classes,IdHTTP, IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient;
var i,j:integer; http1 : TIdHTTP; stream : TFileStream; IP,Pfad,results :TStringList;
begin stream:=TFileStream.Create('bla.txt', fmCreate); http1:=TIDHTTP.Create(nil); IP:=TStringList.Create; Pfad:=TStringList.Create; for i := 1 to ParamCount do if ParamStr(i) = '-pma' then begin try IP.LoadFromFile('hosts.txt'); Pfad.LoadFromFile('path.txt'); for j := 1 to IP.Count-1 do http1.Get('http://'+IP[j]+Pfad[j]+'main.php',stream); WriteLn('http://'+IP[j]+Pfad[j]+'main.php'); finally IP.Free; Pfad.Free; stream.Free; end; end; WriteLn(Paramstr(1));
end. |
nun zu meinem problem: wenn ich die exe starte, stürzt sie sofort ab und dann kommt folgende Fehlermeldung:
Exception EStringListError in module Project1.exe at 00014BE1.
List index out of bounds (2147348480).
Hat jemand ne Idee worans liegt? Bin ratlos :/