Solved

Uploading to the web

Posted on 2000-04-10
11
162 Views
Last Modified: 2010-05-02
Is there any way I can easily upload files to the Internet using VB6? I can download text and HTL with the Inet control, but I need to be able to upload things too.
0
Comment
Question by:mi5
  • 6
  • 5
11 Comments
 
LVL 9

Accepted Solution

by:
samopal earned 70 total points
ID: 2700097
The same way...


Inet1.Execute "Ftp://ftp.myftp.com", _
   "PUT C:\MyDocuments\Send.txt SentDocs\Sent.txt"

HTH
0
 

Author Comment

by:mi5
ID: 2700496
If I have, say, a web account at geocities, is it possible to send a text file there (using ftp.geocities.com)? Geocities requires a user name and password for ftp as each user has their own folder.
0
 
LVL 9

Expert Comment

by:samopal
ID: 2700588
Sure..

Inet1.Execute "ftp://UserName:password@ftp.geocities.com", _
   "PUT C:\MyDocuments\Send.txt SentDocs\Sent.txt"


HTH
0
 

Author Comment

by:mi5
ID: 2700615
Just one more thing... whats the SentDocs\Sent.txt bit. Is that where it is to be sent to?
0
 
LVL 9

Expert Comment

by:samopal
ID: 2700650
C:\MyDocuments\Send.txt - this is the path to the file on your local computer
SentDocs\Sent.txt - this is the destination path on ftp
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 

Author Comment

by:mi5
ID: 2700660
Just one more thing... whats the SentDocs\Sent.txt bit. Is that where it is to be sent to?
0
 

Author Comment

by:mi5
ID: 2700666
Just one more thing... whats the SentDocs\Sent.txt bit. Is that where it is to be sent to?
0
 

Author Comment

by:mi5
ID: 2700676
If I want it in the 'root' path of my folder, then do I just have Sent.txt without the slash?
0
 
LVL 9

Expert Comment

by:samopal
ID: 2700753
Yes
0
 

Author Comment

by:mi5
ID: 2704031
Thanks for your help - this worked fine. Is there an easier way of downloading files (GET command?)?
0
 
LVL 9

Expert Comment

by:samopal
ID: 2704271
Yes...

strFile = Inet1.OpenURL(URLlocation)

where URLlocation = "http://www....." or "ftp://....."
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
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…

707 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now