Autor Beitrag
bbfan
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 164



BeitragVerfasst: Fr 21.08.09 12:43 
Hallo Leute,

ich bin am Verzweifeln. Ich baue erfolgreich eine FTP Verbindung auf. Doch sobald ich einen Befehl zum Server sende (.put, .RetrieveCurrentDir),
kommt eine Exception "Server ready" und die Verbindung wird unterbrochen.

In einer anderen Software von mir, die auch IdFTP bentzt klappt es einwandfrei. FTP Verbindung erfolgreich mit FileZilla getestet. Passive Mode aktiv.
Die Anwendung ist sehr simple.

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
    ftp_test.Username:=form1.ftpuser.Text; 
    ftp_test.Port:=21;
    ftp_test.Password:=form1.ftppasswort.Text; 
    ftp_test.Host := 'ftp.' + form1.ftpdomain.Text;
    ftp_test.Connect(true,6000);  

procedure TForm2.ftp_testConnected(Sender: TObject);
begin
try
showmessage(ftp_test.RetrieveCurrentDir); // HIER KOMMT DER FEHLER
except
end;
end;


---Moderiert von user profile iconNarses: Beiträge zusammengefasst---

Habs Problem gefunden: Man darf die Uplaod Routine nicht in das Event "onConnted" packen. Da ist der Handshake noch nicht abgeschlossen und der Server noch nicht empfangsbereit.