Autor Beitrag
ralfi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 153



BeitragVerfasst: Mi 02.06.04 10:16 
Hallo!

Ich versuche eine Datei auf den Server zu laden:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
...
var
PicData: TIdMultiPartFormDataStream; 

PicData := TIdMultiPartFormDataStream.Create;
PicData.AddFile('file', Edit1.Text, 'application/zip');
IdHTTP1.Post('http://www.homepage.de/cgi-bin/loadPicture.pl?', PicData);
...


Funktioniert alles perfekt, wenn der Pfad (Edit1.Text) zum Beispiel so aussieht: C:\datei.exe. Aber geht gar nicht, wenn der Pfad Leerzeichen enthält: C:\Dukumente und Einstellungen\Admin\Desktop\Data Files\datei.exe. Liegt es wirklich an den Leerzeichen? Wenn ja, womit kann ich die Leerzeichen ersetzen, damit es funktioniert?


Moderiert von user profile iconPeter Lustig: Code- durch Delphi-Tags ersetzt.
FaTaLGuiLLoTiNe
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 200
Erhaltene Danke: 5

Windows 7, Windows 8.1
Delphi XE
BeitragVerfasst: Mi 02.06.04 10:25 
Mein Tip: Setz' mal überall wo im Pfad Leerzeichen sind stattdessen %20 rein.

Bsp: C:\Dukumente%20und%20Einstellungen\Admin\Desktop\Data%20Files\datei.exe

_________________
<< FaTaLGuiLLoTiNe >>
Rhinoceroses don't play games!
ralfi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 153



BeitragVerfasst: Mi 02.06.04 10:27 
Danke, probiere ich mal! :lol:
MathiasSimmack
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Mi 02.06.04 11:25 
open your eyes
and see me as I really am


;)