Web协议 -- 函数

上一篇 / 下一篇  2015-09-07 15:03:09 / 个人分类:LoadRunner

Web_url
   语法:
   int Web_url(
           const char *name,
           const char *url,
           <Lists of attributes>,
           [EXTRARES,
           <lists of Resource attributes>],
           LAST
           )
返回值 成功时返回LR_PASS (0),失败时返回 LR_FAIL (1)。
name: VuGen中树形视图中显示的名称,在自动事务处理中也可以用做事务的名称。
url:  页面url地址。
List of Attributes
EXTRARES:分隔符,标记下一个参数是资源属性的列表了。
List of Resource Attributes
LAST:属性列表结束的标记符。

=========================
      web_image
=========================
语法:
   int web_image(
                const char*StepName,
                <Lists of attributes>,
                [EXTRARES,
                <LIsts Of Resource Attributes>],
                LAST
                )
返回值 成功时返回LR_PASS (0),失败时返回 LR_FAIL (1)。
参数: StepName:VuGen中树形视图中显示的名称,在自动事务处理中也可以用做事务的名称。
List of Attributes(服务器端和客户端映射的图片):SRC属性是一定会被录制到的,其他的ALT、Frame、TargetFrame、Ordinal则是有的话会被录制到。
1、ALT:描述图象的元素。用鼠标指向图象时,所浮出来的文字提示。
2、SRC:描述图象的元素,可以是图象的文件名. 如: button.gif。也可以使用SRC/SFX来指定图象路径的后缀。所有拥有相同此后缀的字符串都会被匹配到。
3、Frame:录制操作时所在的Frame的名称。
4、TargetFrame:见List of Attributes的同名参数。
5、Ordinal:参见Web_link的同名参数。
List of Attributes(客户端映射的图片):
1、AreaAlt:鼠标单击区域的ALT属性。
2、AreaOrdinal:鼠标单击区域的顺序号。
3、MapName:图象的映射名。
List of Attributes(服务器端映射的图片):尽管点击坐标不属于属性,但还是以属性的格式来使用。
1、Xcoord:点击图象时的X坐标。
2、Ycoord:点击图象时的Y坐标。
EXTRARES:分隔符,标记下一个参数是资源属性的列表了。
List of Resource Attributes:参见List of Resource Attributes一节。
LAST:属性列表结束的标记符。

==================
web_link 
==================
语法: Int web_link (const char *StepName, <List of Attributes>, [EXTRARES, <List of Resource Attributes>,] LAST );
返回值 成功时返回LR_PASS (0),失败时返回 LR_FAIL (1)。
参数: StepName:VuGen中树形视图中显示的名称,在自动事务设置中也被用做事务名称。
List of Attributes:支持下列的属性:
1. Text:超链接中的文字,必须精确匹配。
2. Frame:录制操作时所在的Frame的名称。
3. TargetFrame、ResourceByteLimit:见List of Attributes一节。
4. Ordinal:如果用给出的属性(Attributes)筛选出的元素不唯一,那么VuGen使用此属性来指定其中的一个。例如:“SRC=abc.gif”,“Ordinal=3”标记的是SRC的值是“abc.gif”的第3张图片。
EXTRARES:表明下面的参数将会是list of resource attributes了。
LAST:结尾标示符。

=================
web_submmit_form 
=================
语法: Int web_submit_form. (const char *StepName, 
                           <List of Attributes>, 
                          <List of Hidden Fields>, 
                           ITEMDATA, 
                           <List of Data Fields>, 
                  [ EXTRARES, <List of Resource Attributes>,]
                           LAST );
返回值 成功时返回LR_PASS (0),失败时返回 LR_FAIL (1)。

======================
web_submmit_data 
======================
语法: Int web_submit_data ( const char *StepName, 
                           <List of Attributes>,
                            ITEMDATA, 
                            <List of data>, 
                [ EXTRARES, <List of Resource Attributes>,] 
                            LAST );
返回值 返回LR_PASS(0)代表成功,LR_FAIL(1)代表失败。

.
.
.
.
.
如果你需要具体了解,附件下载


TAG:

 

评分:0

我来说两句

Open Toolbar