Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Automate Download Dialog Box

Status
Not open for further replies.

RECrerar

Technical User
Aug 18, 2008
2
GB
Hi,

Firstly a disclaimer:
I know there are several threads on this topic on the web, but I have been unable to find one that actually helps, so here goes.

I am linking through Access VBA to a website, on this webiste I have to populate some option boxes before downloading a file. This I have done. When the file downloads I am then faced with the download dialog box which I would also like to automate to save the file in a known location, say on the C drive. Using sendkeys I can get it to save on my desktop/default location, but there are problems with this:
1. I need to set a delay before sending the sendkeys that is far longer than normally needed to ensure the dialog box is there before activating them, this slows down the process and also gives the user time to change the window focus resulting in the process not working.
2. The desktop is not the ideal location to save the file as the path to this involves the users login name which will be different for every user and I need to use the path to the file in a later part of the program. While I can write the code to retrieve the path it seems a lot more long winded than just being able to save it to the C drive.

Therefore can anyone tell me how to get the programto know when the dialog pop-up has appeared and then to remotely control the download dialog box, preferably without the use of sendkeys. Even links to useful threads I may have missed (I have searched throughly) would be good.

Thanks in advance, Robyn.

PS, I have no access to the website's source code so any methods using this will not be appropriate
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top