VB6>WebBrowser> How to get the NAME of the file that user downloads with RIGHT-click?
I am programming the VB6 application that uses the MS Webbrowser control. I have a question.
How to detect the name of the file that user downloads from web site? (I mean not the source .html file, but the file that user downloads from site with right-click).
In another words: user right-clicks the object on web form, selects the "Save target as:" and downloads file to his/her machine. It can be the .pdf document, .jpg picture, .zip file, .mp3 music etc. How my application can find out (and later to insert into database of downloaded files) the name of downloaded file and (if possible) location on local machine to where user downloaded the file?
Thanks! :)
Re: VB6>WebBrowser> How to get the NAME of the file that user downloads with RIGHT-cl
As far as I know you can't.
This is by design. Browsers work very hard to isolate such things from the object model, historically to prevent potentially malicious script from interfering.
Web scraping in general is a dubious endeavor. If a web site does not explicitly permit such activity in a statement of its terms of use then web scraping is implicitly prohibited - as a function of copyright law is nothing else.
2 Attachment(s)
Re: VB6>WebBrowser> How to get the NAME of the file that user downloads with RIGHT-cl
I.E. 9.0 and other browsers are actually provide users with "View downloads" feature. Just click "ctrl+J" in I.E. 9.0.
I.e. this functionality is not forbidden. Question is however how to code this function in my application??... :confused:
Attachment 112171Attachment 112173