?
Solved

how to up load a folder and put a my text file by FTP

Posted on 2007-11-26
3
Medium Priority
?
260 Views
Last Modified: 2013-11-29
Hello,
i trying to make a code that can upload a text file in a folder(named by me)to my web ftp space server.how can a create a folder in that web space and put the file with the PUT instruction?
i am waiting for yours kidn response



0
Comment
Question by:aitsu01
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
ID: 20348947
To create a directory in ftp have a look at

http://www.example-code.com/vb/ftp_createRemoteDir.asp
http://www.example-code.com/vb/ftp_passiveUpload.asp
http://www.example-code.com/vb/ftp_passiveUpload.asp
http://www.example-code.com/vb/ftp_createPlan.asp

All the examples in these sites uses a third party active x . This is just to give you some ideas. I am not sure to how much extent this will help you.
0
 

Author Comment

by:aitsu01
ID: 20349074


Hello experts,
i 've attahced here my VB6 code here:

    If LCase$(Left$(host_name, 6)) <> "ftp://" Then host_name = "ftp://" & host_name
    inetFTP.URL = host_name

    inetFTP.UserName = txtUserName.Text
    inetFTP.Password = txtPassword.Text
    ora = CStr(Time)
    inetFTP.Execute , "Put " & _
          "c:\lmytextfile.txt" & vbCrLf

My purpose is to upload on the my ftp web  space the "mytextfile.txt" in a folder that i create at the moment,for example with the time .so the file it will be uploaded in the folder " /11.30.00/mytextfile.txt.
How can a create a folder like the exmaple abouve here?thank you.

0
 
LVL 26

Accepted Solution

by:
EDDYKT earned 750 total points
ID: 20349349
have you tried

inetFTP.Execute , "mkdir directory"
inetFTP.Execute , "cd directory"
inetFTP.Execute , "Put c:\lmytextfile.txt" & vbCrLf
0

Featured Post

Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Configuring network clients can be a chore, especially if there are a large number of them or a lot of itinerant users.  DHCP dynamically manages this process, much to the relief of users and administrators alike!
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses
Course of the Month9 days, 9 hours left to enroll

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question