回放时报错
一段脚本,运行到脚本的第4行时报错,multi_bs_def_cell_id_t_666666_24826中的24826每次都变。Window SetContext, "Caption=http://172.20.24.5:9080/bill/billing/baseinfo/feeparam/basegroup/cell_group_multiInsert.jsp?met - Microsoft Internet Explorer", ""
Browser NewPage,"",""
CheckBox Click, "Name=multi_bs_def_cell_id_t_666666_24826"
我曾经试过CheckBox Click, "HTMLText=666666_1",不好用
用inspector抓取出的结果
CheckBox,Name=multi_bs_def_cell_id_t_666666_24947
Contents
HTML Text
Filtered Contents
Properties
id =
tagName = INPUT
title =
language =
sourceIndex = 82
lang =
offsetLeft = 3
offsetTop = 1
offsetWidth = 125
offsetHeight = 20
innerHTML =
innerText =
outerHTML = <INPUT type=checkbox value=666666_1 name=multi_bs_def_cell_id_t_666666_24947>
outerText =
isTextEdit = False
scopeName = HTML
currentStyle = Object
Property was not expanded
tabIndex = 0
accessKey =
clientHeight = 20
clientWidth = 125
clientTop = 0
clientLeft = 0
readyState = complete
dir =
scrollHeight = 20
scrollWidth = 125
scrollTop = 0
scrollLeft = 0
canHaveChildren = False
tagUrn =
readyStateValue = 4
isMultiLine = False
canHaveHTML = False
inflateBlock = False
contentEditable = inherit
isContentEditable = False
hideFocus = False
disabled = False
isDisabled = False
glyphMode = 0
uniqueNumber = 2
uniqueID = ms__id2
nodeType = 1
nodeName = INPUT
dataFld =
dataSrc =
dataFormatAs =
type = checkbox
value = 666666_1
name = multi_bs_def_cell_id_t_666666_24947
status = False
size = 20
maxLength = 2147483647
defaultValue = 666666_1
readOnly = False
indeterminate = False
defaultChecked = False
checked = False
border =
vspace = 0
hspace = 0
alt =
src =
lowsrc =
vrml =
dynsrc =
complete = False
loop = 1
align =
width = 0
height = 71165860
Start = fileopen
accept =
useMap =
HTML Text属性中的值为<INPUT type=checkbox value=666666_1 name=multi_bs_def_cell_id_t_666666_24947> CheckBox Click, "Name={multi_bs_def_cell_id_t_666666*}"
试试~ 修改成CheckBox Click, "Name={multi_bs_def_cell_id_t_666666*}"还是报错。
我修改成CheckBox Click, "VisualText=666666_1",回放时不报错,但回放时没有选中该CheckBox 是不是这个页面中还有其他VisualText=666666_1的? 解决了,'CheckBox Click, "Index=1" 原帖由 wsryyffs 于 2006-11-1 07:44 发表
解决了,'CheckBox Click, "Index=1"
记得robot可以使用不同的属性来定位一个object,但是在你抓的属性中没有看到index啊 抓的属性确实没有index,只是我的同事突然来灵感,一试果然好用,呵呵
页:
[1]