A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Fill out web form with VB



 
 
Thread Tools Display Modes
  #1  
Old May 24th, 2004, 04:55 PM
Nelson
external usenet poster
 
Posts: n/a
Default Fill out web form with VB

I am trying to automatically login to a website with Access VB. Here is the
pertenent html code for the page (with identifiable info changed for
security):

TD class=ftr align=middleSign-on with your User ID and Password. Your
password is case sensitive./TD/TR/TBODY/TABLE
TABLE width="80%" align=center bgColor=#efefef
TBODY
TR
TD align=right width="50%"BUsername:/B/TD
TD align=leftINPUT maxLength=10 size=10 name=username/TD/TR
TR
TD align=right width="50%"BPassword:/B/TD
TD align=leftINPUT type=password maxLength=15 size=10 value=""
name=userpassword/TD/TR
TR
TD align=middle colSpan=2
HR SIZE=2
INPUT type=submit value=Login BRBRA
onclick='window.open("http://www.website.com/docs/cookieuse.htm","",windowFe
atures="height=450,width=600,resizable,scrollbars, alwaysRaised,dependent")'
FONT size=-1Our Use of Cookies/FONT/A
BR/TD/TR/TBODY/TABLE/TD/TR/TBODY/TABLE
TABLE cellSpacing=0 cellPadding=0 width="100%" border=0

This is the code I am using:

Dim Ie As Object

Set Ie = CreateObject("InternetExplorer.Application")
Ie.Navigate "https://secure.freeclaims.com/docs/membermain.asp"
Ie.Visible = True
Do While Ie.Busy
DoEvents
Loop

Ie.Document.All("username").Value = "myname"
Ie.Document.All("userpassword").Value = "xxpasswordxx"
Ie.Document.All("Login").Click '***THIS DOES NOT CLICK THE BUTTON***

Set Ie = Nothing

The correct page comes up in IE, username & userpassword are entered
correctly but the login button is not clicked. What do I need to do to
click the button? Also how do I maximize the IE window?

Thanks in advance.


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:53 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.