Jump to content

Gmail 'Check email from other accounts' speeduper


slaughter
 Share

Recommended Posts

Emails if is taken from other sources gmail account some times takes ages to arrive or you have very time to do it by yourself going in option and clicking "Check mail now"

Solution is automated script witch does it for you while your pc is running.

Has one problem

ID of elements 'Check_mail_now' always changing so you have to adjust it, maybe someone can offer solution?

At his moment it clicks on tow other accounts, but you can always add more. :)

 

Sorry for posting maybe in wrong section, it is like an demo but needs some help :) Maybe admins can move topic to help section. Thanks.

#cs ----------------------------------------------------------------------------

 AutoIt Version: 3.3.8.1
 Author:         myName

 Script Function:
    Template AutoIt script.

#ce ----------------------------------------------------------------------------

; Script Start - Add your code below here
$url1="https://accounts.google.com/ServiceLogin?service=mail&continue=https://mail.google.com/mail/"
$url2="https://mail.google.com/mail/u/0/?shva=1#settings/accounts"
$email="xxx@gmail.com"
$password="my password"
$check_interval_min="2"
$id_of_Check_mail_now1 = ":f42"
$id_of_Check_mail_now2 = ":f46"



#include <IE.au3>
Local $oUser, $oPass, $oSubmit, $oInput
$oIE = _IECreate ($url1,1,0)
_IELoadWait($oIE)


Local $oForm = _IEFormGetObjByName($oIE, "gaia_loginform")
Local $input_username = _IEFormElementGetObjByName($oForm, "Email")
_IEFormElementSetValue($input_username, $email)
Local $input_userpass = _IEFormElementGetObjByName($oForm, "Passwd")
_IEFormElementSetValue($input_userpass, $password)
ConsoleWrite("form submit1."&@CRLF)
Local $oSubmit = _IEGetObjByName($oIE, "signIn")
_IEAction($oSubmit, "click")
;_IEFormSubmit($oForm)
ConsoleWrite("form submit2."&@CRLF)
_IELoadWait($oIE)
Sleep(4000)
ConsoleWrite("Login complete. Navignating to settings."&@CRLF)
_IENavigate($oIE, $url2)
_IELoadWait($oIE)
Sleep(2000)


While 1
    $oDiv = _IEGetObjById($oIE, $id_of_Check_mail_now1)
    _IEAction($oDiv, "click")
    $oDiv = _IEGetObjById($oIE, $id_of_Check_mail_now2)
    _IEAction($oDiv, "click")
    Sleep($check_interval_min*1000*60)
WEnd
Edited by slaughter
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

×
×
  • Create New...