this is what I have, it populates the username and password fine but it will not log in.
VBA Code:
Public Sub Eco() Const strURL_c As String = "[http://www.btwholesale.com/]" Dim objIE As SHDocVw.InternetExplorer Dim ieDoc As MSHTML.HTMLDocument Dim tbxPwdFld As MSHTML.HTMLInputElement Dim tbxUsrFld As MSHTML.HTMLInputElement Dim btnSubmit As MSHTML.HTMLInputElement On Error GoTo Err_Hnd 'Create Internet Explorer Object Set objIE = New SHDocVw.InternetExplorer 'Navigate the URL objIE.navigate strURL_c 'Wait for page to load Do Until objIE.readyState = READYSTATE_COMPLETE: Loop 'Get document object Set ieDoc = objIE.document 'Get username/password fields and submit button. Set tbxUsrFld = ieDoc.all.Item("USER") Set tbxPwdFld = ieDoc.all.Item("PASSWORD") Set btnSubmit = ieDoc.all.Item("LOGIN") 'Fill Fields tbxUsrFld.Value = Worksheets("Login Data").Range("C5").Value tbxPwdFld.Value = Worksheets("Login Data").Range("D5").Value 'Click submit btnSubmit.Click 'Wait for page to load Do Until objIE.readyState = READYSTATE_COMPLETE: Loop Err_Hnd: '(Fail gracefully) objIE.Visible = True End Sub