?
Solved

VBA: How to download file to disk from site with authenticated login id and password

Posted on 2003-10-26
4
Medium Priority
?
566 Views
Last Modified: 2012-06-27
In VBA, I would like to be able to click on a button and have a file downloaded from a site to my harddrive.  The site where the file is located requires a login UserID and password.
I've successfully have this working with a WSH script, however, I need this to work from VBA.

I've tried the URLDownloadToFile API but it doesn't accomodate for username/password arguments.

Any thoughts?
0
Comment
Question by:wonda04
[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
  • 2
4 Comments
 
LVL 30

Expert Comment

by:nmcdermaid
ID: 9625652
Why don't you post the appropriate WSH code then we can convert it to VB.
0
 
LVL 16

Accepted Solution

by:
Richie_Simonetti earned 500 total points
ID: 9626592
should you pass this call in urldownloadtofile?


"http://username:password@www.domain.com/somefolder/somefile.xxx"
0
 

Author Comment

by:wonda04
ID: 9631806
Thanks Richie_Simonetti.  I obviously missed the obvious. = )
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 9633539
"I obviously missed the obvious."

Why?, we have times of shine and times of darkness (All of us).
;)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month11 days, 16 hours left to enroll

752 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