Here's a simple GUI to login into a website (in this case craigslist).
I want to recreate this using Firefox instead of IE.
Can someone help?
Thanks,
Ed
#include <IE.au3>
#include <GUIConstants.au3>
#include <File.au3>
GUICreate ("Acess Website GUI",600,300)
GUISetBkColor (0x99FFCC)
GUISetState(@SW_SHOW)
GUICtrlCreateLabel("Click a button to begin...", 30, 10, 200)
GUICtrlSetFont (-1,12, 800, 2, "Arial")
Opt("GUICoordMode",1)
$button1 = GUICtrlCreateButton ("Craigslist", 40, 60, 100)
$close = GUICtrlCreateButton ("Close", 260, 260, 80)
While 1
$msg = GUIGetMsg()
Select
Case $msg = $button1
$account="email@email.com"
$pw="password"
Account($account,$pw)
Case $msg = $close
$msg = $GUI_EVENT_CLOSE
ExitLoop
Case $msg = $GUI_EVENT_CLOSE
ExitLoop
EndSelect
WEnd
Exit
;FUNCTIONS
Func Account($account,$pw)
$oIE = _IECreate()
_IENavigate($oIE, "https://accounts.craigslist.org/")
$o_form = _IEFormGetObjByName($oIE, "login")
$o_login = _IEFormElementGetObjByName($o_form, "inputEmailHandle")
$o_password = _IEFormElementGetObjByName($o_form, "inputPassword")
_IEFormElementSetValue($o_login,$account)
_IEFormElementSetValue($o_password, $pw)
Sleep(500)
_IEFormSubmit($o_form)
EndFunc