Jump to content

IE Login


burger
 Share

Recommended Posts

I cannot get the following code to produce the login text. Any ideas would be appreciated.

#include <IE.au3>

$oIE = _IECreate()
_IENavigate($oIE, "http://www.investnbest.com/members/Inside_InTouch5.htm")

WinActivate("Connect to www.investnbest.com", "")
ControlSetText("Connect to www.investnbest.com", "", 1005, "username")
ControlSetText("Connect to www.investnbest.com", "", 1006, "password")
Link to comment
Share on other sites

I cannot get the following code to produce the login text. Any ideas would be appreciated.

#include <IE.au3>

$oIE = _IECreate()
_IENavigate($oIE, "http://www.investnbest.com/members/Inside_InTouch5.htm")

WinActivate("Connect to www.investnbest.com", "")
ControlSetText("Connect to www.investnbest.com", "", 1005, "username")
ControlSetText("Connect to www.investnbest.com", "", 1006, "password")
;)

Investment site?

For a 3rd party program inputting sensitive information?

:lmao::evil::mad: Danger Will Robinson!! Danger!!! :o:D:nuke:

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

Link to comment
Share on other sites

Thanks but I think I'm almost there. The script pauses until I open another browser window with a new URL. Once the new URL loads, my script continues and fills in the text. Something is causing it to pause and I think it is IENavigate or IECreate.

Link to comment
Share on other sites

I got to work. Here's the code in case it can help others. Rather than navigate to the protected page, used the mouse to click on the link. This got rid of the pause that occured with IENavigate.

Opt("WinWaitDelay",100)
Opt("WinTitleMatchMode",4)
Opt("WinDetectHiddenText",1)
Opt("MouseCoordMode",0)
WinWait("Purposeful Investing in the Stock Market - Windows Internet Explorer","")
If Not WinActive("Purposeful Investing in the Stock Market - Windows Internet Explorer","") Then WinActivate("Purposeful Investing in the Stock Market - Windows Internet Explorer","")
WinWaitActive("Purposeful Investing in the Stock Market - Windows Internet Explorer","")
MouseMove(195,417)
MouseDown("left")
MouseUp("left")
WinWait("Connect to www.investnbest.com","")
ControlSetText("Connect to www.investnbest.com", "", "Edit2", "username")
ControlSetText("Connect to www.investnbest.com", "", "Edit3", "password")
Link to comment
Share on other sites

#include <IE.au3>

$url = "www.investnbest.com/members/Inside_Touch5.htm"
$oIE = _IECreate($url, 1, 1, 0)
sleep(2000)
$title = "Enter Network Password"
$text = "Please type your user name and password."
WinWaitActive($title)
$username = "Joe Blow"
$password = "password"
ControlSend($title, $text, "Edit1", $username)
sleep(50)
ControlSend($title, $text, "Edit2", $password)

The page never actually completes loading, it waits for you to enter your username and password first. So your script was hung up at the IENavigate. Telling the script NOT to wait for the page to load, and using a sleep instead, cured the problem.

IE Dev ToolbarMSDN: InternetExplorer ObjectMSDN: HTML/DHTML Reference Guide[quote]It is surprising what a man can do when he has to, and how little most men will do when they don't have to. - Walter Linn[/quote]--------------------[font="Franklin Gothic Medium"]Post a reproducer with less than 100 lines of code.[/font]
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...