Hi I am new to programming and was trying to get a form button to load the yahoo login webpage, wait until the send button was loaded and auto enter the username and password and hit the send button. My code is as follows
It doens't like any of this
VB.NET:
Public Class WebLogin
Dim ie As Object
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
ie = CreateObject("internetexplorer.application")
ie.Navigate("login.yahoo.com")
ie.visible = True
While ie.Document.GetElementById(".save") Is Nothing
End While
ie.Document.GetElementById("login").SetAttribute("value", TextBox1.Text)
ie.Document.GetElementById("passwd").SetAttribute("value", TextBox2.Text)
ie.Document.GetElementById(".save").InvokeMember("click")
End Sub
End Class
VB.NET:
While ie.Document.GetElementById(".save") Is Nothing
End While
ie.Document.GetElementById("login").SetAttribute("value", TextBox1.Text)
ie.Document.GetElementById("passwd").SetAttribute("value", TextBox2.Text)
ie.Document.GetElementById(".save").InvokeMember("click")