lcyu888 发表于 2008-6-5 16:58:08

loadrunner中取值

loadrunner中,

值为:
code:'AR:419700',
想用web_reg_save_param取上面内容的值,写法如下:
web_reg_save_param( "flowcontextid2", "LB=code:'", "RB='","Ord=4","IgnoreRedirections=Yes", "Search=All",LAST );

上面取值方式写的对吗?
请帮着看看

Zee 发表于 2008-6-5 17:12:11

‘需要\转义。

lcyu888 发表于 2008-6-5 17:28:42

在哪加 \

iori 发表于 2008-6-5 17:37:05

说错了,呵呵

[ 本帖最后由 iori 于 2008-6-6 09:08 编辑 ]

Zee 发表于 2008-6-5 17:39:14

单引号前面。不是后面。

lcyu888 发表于 2008-6-5 17:43:26

试过了,不行呢

Zee 发表于 2008-6-5 17:57:31

估计是你写错了。你应该把你的脚本和你自己写的关联语句都帖上来。

lcyu888 发表于 2008-6-6 08:42:36

log中的内容如下:
apps.push({ id:'carryCondition',
                        text:'落实条件',
                        code:'AR:419700',
                        url:'/cb/cbCarryOutConditionAction!init.action ',icon:''});

想取上面中的值:AR:419700

用web_reg_save_param的语句如下,
web_reg_save_param( "flowcontextid2", "LB= code:'", "RB='","Ord=4","IgnoreRedirections=Yes", "Search=All",LAST );

执行后,总是报:
Action.c(223): Error -26377: No match found for the requested parameter "flowcontextid1". Check whether the requested boundaries exist in the response data. Also, if the data you want to save exceeds 1024 bytes, use web_set_max_html_param_len to increase the parameter size         

云层 发表于 2008-6-6 09:07:17

web_reg_save_param( "flowcontextid2", "LB= code:\'", "RB=\'","Ord=4","IgnoreRedirections=Yes", "Search=All",LAST );

try again

aks5201314 发表于 2008-6-6 15:59:15

1.web_reg_save_param()函数在脚本里的位置是否正确,楼主再好好检查一下
2.web_reg_save_param( "flowcontextid2", "LB/IC= code:\'", "RB/IC=\'","Ord=1","IgnoreRedirections=Yes", "Search=All",LAST );:victory:
页: [1]
查看完整版本: loadrunner中取值