Jump to content
Sign in to follow this  
z32tt

Help with entering text into internet explorer textbox

Recommended Posts

z32tt

I'm sure this is very easy for you guys, but I am new to writing code and this is killing me.

I've been trying this for hours, but it's not working. Internet explorer starts and the webpage loads, but nothing happens after that, it doesn't put the text into the login box. The password I will enter manually without the script.

#include <IE.au3>
$oIE = _IECreate("something.com")
_IELoadWait ($oIE)
$oForm = _IEFormGetObjByName($oIE, "aspnetForm")
; Get reference to the input via the form object and the inputs name property
$oInput = _IEFormElementGetObjByName($oForm, "ctl00$cphMainContent$txtLoginId")
; Set a new value for the input object
_IEFormElementSetValue($oInput, "Test")

post-72443-0-59334500-1337022815_thumb.g

Edited by z32tt

Share this post


Link to post
Share on other sites
z32tt

Hmm, apparently logins are against forum rules (even though this is actually for a local intranet script to get a machine on the domain). Please delete, thanks.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×