How to find out the link of an element id
I am trying to make a youtube downloader. This works via the webbrowser ,
so for example the user types in the link of the youtube video in my
textbox1 and the webbrowser redirects to "mp4.ee" and inserts the link and
then it automatically clicks download. However once you click download on
mp4.ee, another download button appears. And here lies my problem, if I
click on the second download link it will ask me to save the file however
I want to find out the link of the second download button since I want my
program to download the file automatically with it's downloader. My codes:
Code to insert link into mp4.ee and press download:
WebBrowser1.Document.GetElementById("Form").SetAttribute("value",
TextBox1.Text)
WebBrowser1.Document.GetElementById("Button").InvokeMember("click")
Application.DoEvents()
With this code it click the second download button which then asks you to
save the file however I want to find out the link this button contains in
string format:
WebBrowser1.Document.GetElementById("PopupWindowButton").InvokeMember("click")
No comments:
Post a Comment