![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | How to get DOM on the landing page after a submit using aInternetExplorer.Application Obj The following script visits a website log in page, does a POST, and then navigates to the site's welcome page. The Welcome page has a div whose id is "AAA". But the IE object isn't getting refreshed with the DOM on the Welcome page to see it. What do I need to do? Thanks. Set IE = CreateObject("InternetExplorer.Application") IE.Visible = True IE.navigate "http://www.mywebsite.com" Do while IE.Busy Loop Set doc = IE.Document Set form = doc.forms("login_form") form.elements("password").value = "mypassword" form.elements("logon").value = "mylogin" form.submit Do while IE.Busy Loop IE.Refresh -- Refresh isn't making it so I can see the DOM on the Welcome page Set doc = IE.Document Set msg = doc.getElementById("AAA") MsgBox msg.innerHTML ' Always null |
My System Specs![]() |
| | #2 (permalink) |
| | Re: How to get DOM on the landing page after a submit using aInternetExplorer.Application Obj Nevermind. This did it: IE.Navigate IE.LocationURL '''' Set IE = CreateObject("InternetExplorer.Application") IE.Visible = True IE.navigate "http://www.mywebsite.com" Do while IE.Busy Loop Set doc = IE.Document Set form = doc.forms("login_form") form.elements("password").value = "mypassword" form.elements("logon").value = "mylogin" form.submit Do while IE.Busy Loop IE.Navigate IE.LocationURL Set doc = IE.Document Set msg = doc.getElementById("AAA") MsgBox msg.innerHTML ' Works now |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| Can'T submit form data from mail | Vista mail | |||
| Using only 1/3 page file, but unable to load application | Vista General | |||
| Using only 1/3 page file, but unable to load application | Vista General | |||
| submit page | PowerShell | |||
| How to submit page | PowerShell | |||