Compatible Support Forums: Need Help with FTP.EXE

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Need Help with FTP.EXE

#1 User is offline   GHz 

  • newbie
  • Group: Members
  • Posts: 21
  • Joined: 14-May 00

Posted 16 April 2003 - 05:00 PM

I'm trying to use FTP.EXE to send and get files with spaces in them. For instance, it works fine with a file such as "myfile.txt" but fails with "my file.txt". Does anyone know how to get this working? I tried using the 'literal' command with 'RETR my file.txt' but that seems to hang the software. I am quite aware that I could be using another FTP client, but I need FTP.EXE to work because I've tied it into my program. If you don't know how to solve the problem with FTP.EXE, suggesting another command-line program would be useful. Thanks in advance.

GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
0

#2 User is offline   ViolentGreen 

  • addict
  • Group: Members
  • Posts: 557
  • Joined: 28-March 03

Posted 16 April 2003 - 06:00 PM

Quote:
I'm trying to use FTP.EXE to send and get files with spaces in them. For instance, it works fine with a file such as "myfile.txt" but fails with "my file.txt". Does anyone know how to get this working? I tried using the 'literal' command with 'RETR my file.txt' but that seems to hang the software. I am quite aware that I could be using another FTP client, but I need FTP.EXE to work because I've tied it into my program. If you don't know how to solve the problem with FTP.EXE, suggesting another command-line program would be useful. Thanks in advance.

GHz
http://www.planetquake.com/vortex
ghz@planetquake.com


Try putting the file name in quotes (try "my file.txt" first and then 'my file.txt')
0

#3 User is offline   GHz 

  • newbie
  • Group: Members
  • Posts: 21
  • Joined: 14-May 00

Posted 16 April 2003 - 06:09 PM

That's the first thing I tried. Doesn't work frown

GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
0

#4 User is offline   adamvjackson 

  • Pooh-Bah
  • Group: Members
  • Posts: 2174
  • Joined: 26-August 02

Posted 16 April 2003 - 08:27 PM

Did you try including the full path to the filename?
0

#5 User is offline   ViolentGreen 

  • addict
  • Group: Members
  • Posts: 557
  • Joined: 28-March 03

Posted 16 April 2003 - 09:14 PM

OK then. What about using the %20 instead of a space?[/i]
0

#6 User is offline   duhmez 

  • addict
  • Group: Members
  • Posts: 583
  • Joined: 27-April 02

Posted 16 April 2003 - 10:15 PM

Homeboy has got it right. Anywhere there would be a spcae, put %20 instead.
0

#7 User is offline   GHz 

  • newbie
  • Group: Members
  • Posts: 21
  • Joined: 14-May 00

Posted 17 April 2003 - 02:30 AM

Yes, my application creates the script files dynamically based upon user input. If you're really curious, I'm using the FTP as a subsystem to transfer character data to and from my Quake 2 server to a master FTP database. This allows players of my Q2 RPG mod to play their character from any server, provided they have my special software (and FTP.EXE of course!).

Thanks for the help guys, I'll try out your suggestions tonight.

GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
0

#8 User is offline   ViolentGreen 

  • addict
  • Group: Members
  • Posts: 557
  • Joined: 28-March 03

Posted 17 April 2003 - 03:32 PM

Quote:
Yes, my application creates the script files dynamically based upon user input. If you're really curious, I'm using the FTP as a subsystem to transfer character data to and from my Quake 2 server to a master FTP database. This allows players of my Q2 RPG mod to play their character from any server, provided they have my special software (and FTP.EXE of course!).

Thanks for the help guys, I'll try out your suggestions tonight.

GHz
http://www.planetquake.com/vortex
ghz@planetquake.com


Why don't you just write the ftp into the software. I don't know what kind of language you are using but I doubt it is that hard to do. You could probably find a library out there with all the socket based programming done for you. It would take away the need for FTP.exe. Just something to think about, especially if my above suggestion doesn't work.
0

#9 User is offline   ViolentGreen 

  • addict
  • Group: Members
  • Posts: 557
  • Joined: 28-March 03

Posted 18 April 2003 - 01:04 AM

Quote:
Quote:
Quote:
Yes, my application creates the script files dynamically based upon user input. If you're really curious, I'm using the FTP as a subsystem to transfer character data to and from my Quake 2 server to a master FTP database. This allows players of my Q2 RPG mod to play their character from any server, provided they have my special software (and FTP.EXE of course!).

Thanks for the help guys, I'll try out your suggestions tonight.

GHz
http://www.planetquake.com/vortex
ghz@planetquake.com


Why don't you just write the ftp into the software. I don't know what kind of language you are using but I doubt it is that hard to do. You could probably find a library out there with all the socket based programming done for you. It would take away the need for FTP.exe. Just something to think about, especially if my above suggestion doesn't work.


Warning him ahead of time: I wrote an FTP client...

I found out that downloading stuff is simpler than uploading them, no question... I got by it & around some hassles I had with it (most all of them I think with MOST ftp servers, but not all), but was headache & VERY frustrating!

In fact, the MOST frustrating problem I have ever run into programming actually!

(This problem boggled my mind for a good 1/2 year in fact, but I wrote it from scratch & did ALOT of porting of the C/C++ code for it to Delphi... I solved it with time & hassle, but it was a PAIN!)

* That's why I was wondering if he was scripting FTP.exe itself...

smile

APK

P.S.=> BUT, VG does have a point: I think that WSFTP's sourcecode is up online & freely available too... no joke! Trick is, he may not be used to the C/C++ code I believe it is written in... apk


I have written a simple http client/server in c. There is pleanty of documentation and source code out there if you wanted to go that way as well. I doubt ftp is much different.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users