找回密码
 加入
搜索
查看: 1627|回复: 6

网页表单问题

[复制链接]
发表于 2008-12-30 10:50:22 | 显示全部楼层 |阅读模式
网址:http://tg.sdo.com/GameZone/Web/GetGamePrize.aspx
结构如图1-3
我的脚本只能做到图4,怎么改才能做成图3的位置
#include <IE.au3>
$oIE = _IECreate ("http://tg.sdo.com/GameZone/Web/GetGamePrize.aspx")
$oForm = _IEFormGetObjByName ($oIE, "form1")
$oQuery = _IEFormElementGetObjByName ($oForm, "txt_UserName")
_IEFormElementSetValue ($oQuery, "longzp001")
$oQuery = _IEFormElementGetObjByName ($oForm, "ddlGames")
_IEFormElementOptionSelect ($oQuery , 1, 1, "byIndex")
$oQuery = _IEFormElementGetObjByName ($oForm, "ddlGameAreas")
_IEFormElementOptionSelect ($oQuery , 4, 1, "byIndex")
$oQuery = _IEFormElementGetObjByName ($oForm, "ddlGameServer")
_IEFormElementOptionSelect ($oQuery , 1, 1, "byIndex")
$oQuery = _IEFormElementGetObjByName ($oForm, "btn_Post")
_IEAction($oQuery ,"click")


[ 本帖最后由 yt5588 于 2009-3-3 08:09 编辑 ]

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?加入

×
发表于 2008-12-31 00:31:02 | 显示全部楼层
最后一句改成

        _IEFormSubmit($oForm, 1)
试试
 楼主| 发表于 2008-12-31 08:25:33 | 显示全部楼层
不行。。。
发表于 2008-12-31 11:18:46 | 显示全部楼层


#include <IE.au3>
$oForm = _IEFormGetObjByName ($oIE, "form1")
$oQuery = _IEFormElementGetObjByName ($oForm, "txt_UserName")
_IEFormElementSetValue ($oQuery, "longzp001")
$oQuery = _IEFormElementGetObjByName ($oForm, "ddlGames")
_IEFormElementOptionSelect ($oQuery , 1, 1, "byIndex")
$oQuery = _IEFormElementGetObjByName ($oForm, "ddlGameAreas")
_IEFormElementOptionSelect ($oQuery , 108, 1, "byvalue", 1)
$oQuery = _IEFormElementGetObjByName ($oForm, "ddlGameServer")
_IEFormElementOptionSelect ($oQuery , 1, 1, "byIndex")
$oQuery = _IEFormElementGetObjByName ($oForm, "btn_Post")
_IEAction($oQuery ,"click")
_IELoadWait($oIE, 100)
 楼主| 发表于 2009-1-2 21:51:29 | 显示全部楼层
还是不行,好像选别的游戏之后,网页会刷新一下,然后AU3就选不了了
发表于 2009-1-3 10:40:43 | 显示全部楼层
原帖由 yt5588 于 2009-1-2 21:51 发表
还是不行,好像选别的游戏之后,网页会刷新一下,然后AU3就选不了了

你得设置_IELOADWAIT()
 楼主| 发表于 2009-1-5 16:29:41 | 显示全部楼层
原帖由 liongodmien 于 2009-1-3 10:40 发表

你得设置_IELOADWAIT()



不懂怎么设置,老提示出错。。。麻烦了。。
您需要登录后才可以回帖 登录 | 加入

本版积分规则

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

GMT+8, 2024-5-19 02:34 , Processed in 0.072979 second(s), 21 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

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