QQ邮箱(https://mail.qq.com/) 自动登录脚本
Moderators: tmplinshi, arcticir
QQ邮箱(https://mail.qq.com/) 自动登录脚本
想写一个QQ邮箱(https://mail.qq.com/) 自动登录脚本,使用AHKinfo 工具获取用户框和密码框,因用户框和密码框是嵌在iframe中,获取不了 用户框和密码框的代码,请高手帮忙,如何用ahk代码给用户框和密码框赋值,并点击登录按钮,谢谢
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
not best way , I use this for GMX login
Code: Select all
#persistent
SetKeyDelay,25,5
Settitlematchmode,2
[email protected] ; << login
BB=0123456789 ; << code
;FXA=http://www.gmx.ch/
fxa=https://mail.qq.com/ ; << URL
;SC=GMX
SC =QQ ; << see text in browser TAB
IXE=%A_programfiles%\Mozilla Firefox\firefox.exe
;IXE=%A_programfiles%\internet explorer\iexplore.exe
Run,%IXE% %FXA%,,max
WinWait,%SC%
IfWinNotActive ,%SC%,,WinActivate,%SC%
WinWaitActive,%SC%
;- wait until browser is really loaded and then click left mouse button in first login edit field QQ / Email / Mobile
;- wait until left mouse click <<<<<
KeyWait, LButton, D
sleep,4000
send,%AA%
;msgbox, 262144, a,AA=%aa%, 2
sleep,1000
send,{TAB}
sleep,2000
send,%BB%
;msgbox, 262144, a,BB=%bb%, 2
sleep,1000
send,{TAB}
sleep,1000
send,{ENTER}
ExitApp
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
thank you! dont work for QQ mail
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
解决方案来自这个帖子: http://www.autohotkey.com/board/topic/9 ... /?p=578407
Code: Select all
ie := ComObjCreate("InternetExplorer.Application")
ie.Visible := True
ie.Navigate("https://mail.qq.com/")
While, (IE.readystate != 4 || IE.busy)
Sleep, 100
frame := ComObj(9,ComObjQuery(ie.document.getElementById("login_frame").contentWindow,"{332C4427-26CB-11D0-B483-00C04FD90119}","{332C4427-26CB-11D0-B483-00C04FD90119}"),1)
frame.document.getElementById("u").value := "[email protected]"
frame.document.getElementById("p").value := "xxxxxxxxx"
frame.document.getElementById("login_button").Click()
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
thank you tmplinshi
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
在 windows7中运行 tmplinshi 给出的脚本出错,请高手帮助
---------------------------
QQlogin.ahk
---------------------------
Error: No valid COM object!
Line#
001: ie := ComObjCreate("InternetExplorer.Application")
002: ie.Visible := True
003: ie.Navigate("https://mail.qq.com/")
004: While,(IE.readystate != 4 || IE.busy)
005: Sleep,100
---> 006: frame := ComObj(9,ComObjQuery(ie.document.getElementById("login_frame").contentWindow,"{332C4427-26CB-11D0-B483-00C04FD90119}","{332C4427-26CB-11D0-B483-00C04FD90119}"),1)
007: frame.document.getElementById("u").value := "[email protected]"
008: frame.document.getElementById("p").value := "xxxxxx"
009: frame.document.getElementById("login_button").Click()
010: Exit
011: Exit
011: Exit
Continue running the script?
---------------------------
是(Y) 否(N)
---------------------------
---------------------------
QQlogin.ahk
---------------------------
Error: No valid COM object!
Line#
001: ie := ComObjCreate("InternetExplorer.Application")
002: ie.Visible := True
003: ie.Navigate("https://mail.qq.com/")
004: While,(IE.readystate != 4 || IE.busy)
005: Sleep,100
---> 006: frame := ComObj(9,ComObjQuery(ie.document.getElementById("login_frame").contentWindow,"{332C4427-26CB-11D0-B483-00C04FD90119}","{332C4427-26CB-11D0-B483-00C04FD90119}"),1)
007: frame.document.getElementById("u").value := "[email protected]"
008: frame.document.getElementById("p").value := "xxxxxx"
009: frame.document.getElementById("login_button").Click()
010: Exit
011: Exit
011: Exit
Continue running the script?
---------------------------
是(Y) 否(N)
---------------------------
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
不知是不是你的 AHK 版本太低了。在这个网站下载最新版试试。
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
感谢tmplinshi 的回复,我AutoHotkey的版本升级为V1.1.22.00,重启计算机后,运行脚本不会出现上述的错误,但偶尔会出现运行完脚本,用户名和密码会自动输入但不会自动登陆的情况,还有想请教tmplinshi,我的计算机系统是win7,ie版本为IE11,我想实现如果QQ邮箱已经登陆,脚本就自动切换到QQ邮箱的iE标签,否则就新建一个IE标签(不是ie窗口)登陆QQ邮箱,恳请大侠帮忙,谢谢!!!
Re: QQ邮箱(https://mail.qq.com/) 自动登录脚本
请教一下:登录按钮没id怎么处理?tmplinshi wrote:解决方案来自这个帖子: http://www.autohotkey.com/board/topic/9 ... /?p=578407Code: Select all
ie := ComObjCreate("InternetExplorer.Application") ie.Visible := True ie.Navigate("https://mail.qq.com/") While, (IE.readystate != 4 || IE.busy) Sleep, 100 frame := ComObj(9,ComObjQuery(ie.document.getElementById("login_frame").contentWindow,"{332C4427-26CB-11D0-B483-00C04FD90119}","{332C4427-26CB-11D0-B483-00C04FD90119}"),1) frame.document.getElementById("u").value := "[email protected]" frame.document.getElementById("p").value := "xxxxxxxxx" frame.document.getElementById("login_button").Click()
Who is online
Users browsing this forum: No registered users and 70 guests