There are really two basic methods to accomplish this.
1. Post the variables to the URL (i.e.
http://mysite.com/login.html?id=2132&pw=132132). Now the issue with this is a few things. it can become a huge pain if the login site is complex, for example if they are using viewstate variables, or other generated variables. In this case I would definantly go with option 2 )
2.Use element id's and simulate the button click. simply open the page source using any web browser. Find the ID of the login txt box, and the password. In most cases these are (ID = USerName & Id=Pw). Then look up the ID of the Button. Normally (ID = Submit, or ID = Login). The code I use is the following
Lets assume the Id's were (UserName,Pw,Submit), where submit is the button. And lets also assume you were using the Active X Control for the webbrower.
dim x as new axwebbrowser
x.Navigate(
"your website you want to login to")
'You will likley need to add a loop clause here to wait until the Readystate
'is complete i.e. While not x.CurrentState = readystate_Complete loop
'That might not be the exact code, but look up the correct on google
'Then simply do
x.Document.Body.GetElementByID("UserName").value="Vinnie"
x.Document.Body.GetElementByID("Pw").value="1234"
X.Document.Body.GetElementByID("Submit").Click()