找回密码
 加入
搜索

GUI微薄

商品类型:
全新商品
运费:
虚拟物品
剩余时间:
成交结束
商品数量:
1
地点:
上海
累计售出:
0
现价:

50.00 元

原价:
50.00 元
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <IE.au3>
#Region ### START Koda GUI section ### Form=C:\Documents and Settings\Administrator\桌面\ocr\form1.kxf
Dim $usename,$password
$Form1_1 = GUICreate("微薄登陆", 633, 447, 193, 125)
$Radio1 = GUICtrlCreateRadio("新浪微薄", 64, 64, 81, 33)
$Radio2 = GUICtrlCreateRadio("腾讯微薄", 159, 64, 81, 33)
$Group1 = GUICtrlCreateGroup("", 16, 104, 369, 297)
$Label1 = GUICtrlCreateLabel("用户账号", 24, 144, 52, 17)
$Label2 = GUICtrlCreateLabel("用户密码", 20, 259, 52, 17)
$input1=GUICtrlCreateInput("", 152, 136, 225, 21)
$input2=GUICtrlCreateInput("", 152, 240, 225, 21,BitOR($ES_LEFT, $ES_AUTOHSCROLL, $ES_LOWERCASE, $ES_PASSWORD))
$Button1 = GUICtrlCreateButton("登陆", 40, 328, 97, 41, 0)
$Button2 = GUICtrlCreateButton("退出", 264, 328, 97, 41, 0)
GUICtrlCreateGroup("", -99, -99, 1, 1)
GUICtrlSetState(-1, $GUI_HIDE)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
        $nMsg = GUIGetMsg()
        Switch $nMsg
                case $Button1
                        $usename=GUICtrlRead($input1)
                        ;if $usename="" Then MsgBox(0,"错误","请输入用户名!")
                        $password=GUICtrlRead($input2)
                        if $password=""Or $usename=""  Then  MsgBox(0,"错误","用户名或密码不能为空!")
                        $oIE = _IECreate ("http://t.sina.com.cn",0,0,1,1)
            $oUser = _IEGetObjById  ($oIE, "loginname")
                        $oPass = _IEGetObjById  ($oIE, "password")
            _IEFormElementSetValue ($oUser, "$usename")
            _IEFormElementSetValue ($oPass, "$password")
           $oLogin = _IEGetObjById  ($oIE, "login_submit_btn")
           $oLogin.click()
                   _IELoadWait ($oIE)
                   If $oIE.document.getElementById("eHint").innerHTML = '登录名或密码错误 &nbsp;' Then MsgBox(0,'错误提示','密码或账号错误!')

                       
                case $Button2
                        Exit
                Case $GUI_EVENT_CLOSE
                        Exit
                       

        EndSwitch
WEnd

While 1
        $nMsg = GUIGetMsg()
        Switch $nMsg
                Case $GUI_EVENT_CLOSE
                        Exit

        EndSwitch
WEnd
这是自己写的GUI,如果嫌丑,放弃自由发挥。需要实现登陆判断账号密码是否正确,把微薄上关注的人的言论放到GUI上,最好能看评论等等,总之功能越多越好,会额外多付50RMB报酬好的话。上面我自己写的是错的,完成后能加注释就完美了,期待高手莅临实现。。。

信用评价

卖家实名
买家信用
卖家信用

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-5-18 15:40 , Processed in 0.073787 second(s), 20 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表