Autor Beitrag
N47R0N
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 19:19 
So ich bins (mal wieder)

Nun wie ihr wisst habe ich das mit dem speichern hinbekommen jetzt

und ich habe es auch hinbekommen das es zu meinem FTP Server verbindet ich habe jedoch nicht den befehl gefunden zum hochladen ich habe auch schon in der Delphi Hilfe nachgesehen ich will das nach einem klick auf einen button (es ist immer die selbe Datei) eine Datei die sich immer im selben Ordner befindet hochgeladen wird.
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Mo 21.03.05 19:26 
der befehl lautet PUT

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
N47R0N Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 19:39 
Also so sollte der Code dann ungefär aussehen

procedure TForm2.IdFTP1Connected(Sender: TObject);
begin

PUT

end;

end.


soweit so gut und wie gebe ich an in welchem ordner die datei ist die er hochladen soll???
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Mo 21.03.05 19:55 
eher so:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
    idftp1.Host := 'ftp.vol.at';
    idftp1.Username := 'anonymous';
    idftp1.Password := 'user@host.com';
    idftp1.Connect(true, 15);
    idftp1.ChangeDir('/');
    idftp1.put('mytextfile.txt');

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
N47R0N Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 20:04 
In meinem Fall dann


ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
procedure TForm2.IdFTP1Connected(Sender: TObject);
begin
    idftp1.Host := 'ftp.vol.at';
    idftp1.Username := 'anonymous';
    idftp1.Password := 'user@host.com';
    idftp1.Connect(true, 15);
    idftp1.ChangeDir('/');
    idftp1.put('DATA.TXT');
end;

end.
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Mo 21.03.05 20:09 
nein ! den code den ich gepostet habe hängst du einfach an, nachdem das textfile erstellt wurde.

also so:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
...
closefile(f);
idftp1.host := 'ftp....'
...
//usw

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
N47R0N Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 20:18 
Jo hab ich das lässt sich auch alles erstellen nur wenn ich dann auf den Button klicke dann kommt ne fehlermeldung:

Zeitüberschreitung der Verbindung
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Mo 21.03.05 20:21 
kann es sein dass der ftp-server nicht reagiert ?
ansonsten spiele mal mit den paramtern von idftp1.connect rum...

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
N47R0N Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 20:26 
also normal connecten konnte ich schon vorher doch alst jetzt noch deine befehle dazugekommen sind verbindet er nicht mehr
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Mo 21.03.05 20:29 
mach mal aus 15 150, dann sollte es gehen. idftp1.Connect(true, 150);

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
N47R0N Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 20:32 
JUUUUHUUUUUUUUUU ich habs hinbekommen
N47R0N Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 134



BeitragVerfasst: Mo 21.03.05 20:38 
user profile iconN47R0N hat folgendes geschrieben:
JUUUUHUUUUUUUUUU ich habs hinbekommen


Nur eins wäre da noch die datei soll nach dem hochladen dann auch noch gelöscht werden.
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Mo 21.03.05 20:39 

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...