VB.NET - YouTube to MP3 Converter


SUBMITTED BY: Guest

DATE: Oct. 25, 2013, 2:38 p.m.

FORMAT: Text only

SIZE: 1.3 kB

HITS: 1161

  1. In this post. I will teach you how to make your own YouTube to MP3 Converter.
  2. Ok, You will need these..
  3. 1 Web Browser (Visible - False)
  4. 1 Textbox
  5. 2 Buttons
  6. Make it look like this..
  7. http://cur.lv/4cl46
  8. Ok, Let's continue...
  9. In Form1_Load. Add this Code..
  10. WebBrowser1.Navigate("http://www.youtube-mp3.org/")
  11. Button1.Enabled = False
  12. In WebBrowser. Add this Code..
  13. Dim text As String = WebBrowser1.DocumentText
  14. If text.Contains("submit-form") Then
  15. Button1.Enabled = True
  16. Else
  17. Button1.Enabled = False
  18. MsgBox("Could not connect to the internet!", MsgBoxStyle.Information, "Error")
  19. End If
  20. In Button1. Add this..
  21. WebBrowser1.Document.GetElementById("youtube-url").SetAttribute("value", TextBox1.Text)
  22. WebBrowser1.Document.GetElementById("submit").InvokeMember("click")
  23. In Button 2. Add this..
  24. Dim dl_link As HtmlElement = WebBrowser1.Document.GetElementById("dl_link")
  25. Dim links As HtmlElementCollection = dl_link.GetElementsByTagName("a")
  26. Dim url As String = links(0).GetAttribute("href")
  27. System.Diagnostics.Process.Start(url)
  28. HOPE THIS HELPS! oHH YEAH.. You need Internet for this.. :D

comments powered by Disqus