How to accept a download?

Raygar

Member
Joined
Mar 17, 2011
Messages
5
Programming Experience
Beginner
I connects to a site.
On that site, it puts in criteria to filter on a database. It then submits it.
A pop up window appears asking to Open / Save / Cancel. I don't know how to interact with that window.

It is possible to Save, and specify the download location without having to use Sendkeys?
Note: There is no file to directly download. You have to run the report and it kicks back the file.
 

JohnH

VB.NET Forum Moderator
Staff member
Joined
Dec 17, 2005
Messages
15,609
Location
Norway
Programming Experience
10+
Depends on how the download works and what window is actually popping up (for example browser window or system dialog). If the download is the result of a url request WebBrowser control can be used to navigate from requesting page, then using Navigating event the url can be cancelled and picked up for manual download. Other ways could be to use for example Fiddler web debugger tool and watch what requests is actually being sent to server during a manual browsing session and replicate those with a WebClient/HttpWebRequest in VB afterwards.
 
Top Bottom