jingdouyun 发表于 2008-10-20 17:21:58

loadrunner Error 404

各位大侠:
   脚本如下:
脚本不是全的
       Action()
{

      web_url("platform",
                "URL=http://10.0.
                "Resource=0",
                "RecContentType=text/html",
                "Referer=",
                "Snapshot=t1.inf",
                "Mode=HTML",
                EXTRARES,
                "Url=images/login/login_butB.gif", "Referer=http://10.0.1.
                LAST);

      web_submit_form("ess_security_check",
                "Snapshot=t2.inf",
                ITEMDATA,
                "Name=j_username", "Value=", ENDITEM,
                "Name=j_password", "Value=", ENDITEM,
                EXTRARES,
                "Url=ext/resources/images/default/window/left-corners.png", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/window/right-corners.png", "Referer=http://10.0.1.1
                "Url=ext/resources/images/default/window/left-right.png", "Referer=http://10.0.1.                "Url=ext/resources/images/default/window/top-bottom.png", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/panel/left-right.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/panel/corners-sprite.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/toolbar/bg.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/page-first-disabled.gif", "Referer=http://10.0.1.                "Url=ext/resources/images/default/panel/top-bottom.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/page-prev-disabled.gif", "Referer=http://10.0.1.                "Url=ext/resources/images/default/grid/grid-blue-split.gif", "Referer=http://10.0.1.                "Url=ext/resources/images/default/grid/page-next-disabled.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/page-last-disabled.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/done.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/s.gif", "Referer=http://10.0.1.                "Url=ext/resources/images/default/grid/grid3-hrow.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/grid3-hd-btn.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/dd/drop-no.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/col-move-top.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/col-move-bottom.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/form/text-bg.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/button/btn-sprite.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/grid/grid3-hrow-over.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/panel/tool-sprites.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/progress/progress-bg.gif", "Referer=http://10.0.1.
                "Url=ext/resources/images/default/qtip/bg.gif", "Referer=http://10.0
                LAST);

      web_submit_data("showSearchTaskListAC!showSearchTaskListByDirect.action",
                "Action=http://10.0.1.
                "Method=POST",
                "RecContentType=application/json",
                "Referer=http://10.0.1.
                "Snapshot=t3.inf",
                "Mode=HTML",
                ITEMDATA,
                "Name=start", "Value=0", ENDITEM,
                "Name=limit", "Value=10", ENDITEM,
                LAST);

      lr_start_transaction("1QAZ");

      lr_think_time(417);

      web_submit_data("createSearchTaskAC!createSearchTaskByDirect.action",
                "Action=http://10.0.1.
                "Method=POST",
                "RecContentType=application/json",                 "Referer=http://10.0.1.
                "Snapshot=t4.inf",
                "Mode=HTML",
                ITEMDATA,
                "Name=taskInfo", "Value={\"taskName\":\"SDFSADF\",\"taskDetail\":\"ASDFSADFASDF\"}", ENDITEM,
                LAST);

      return 0;
}
报错内容如下:
Action.c(49): web_submit_data("showSearchTaskListAC!showSearchTaskListByDirect.action") was successful, 320 body bytes, 158 header bytes         
Action.c(61): Notify: Transaction "1QAZ" started.
Action.c(65): Error -26627: HTTP Status-Code=404 (Not Found) for "http://      
Action.c(65): web_submit_data("createSearchTaskAC!createSearchTaskByDirect.action") highest severity level was "ERROR", 115 body bytes, 163 header bytes         
Action.c(65): Notify: Transaction "1QAZ" ended with "Fail" status (Duration: 0.2396).
Ending action Action.

请各位大侠看看,多多指教,谢谢了!!!

[ 本帖最后由 jingdouyun 于 2008-11-19 11:19 编辑 ]

jingdouyun 发表于 2008-10-21 17:20:17

没有人知道吗

没有人知道吗

ice1985 发表于 2008-10-21 18:01:21

在VUGen的Tools->Recording Options下的Recoding分支中,
将HTML-based script的单选按钮改为URL-based script
再录制脚本运行下试试呢

Lemon_s 发表于 2008-10-21 18:07:56

为何?

jingdouyun 发表于 2008-10-22 21:33:15

先谢过

试过了还是不行啊

jingdouyun 发表于 2008-10-24 17:39:58

终于解决了

不易啊!需要手写一段代码,因为loadrunner有一段没有录制下来。

xxmao163 发表于 2008-10-30 15:11:07

楼主可否把手写的脚本放上来共享,我也遇到和你同样的问题,但不知道如何手写脚本
页: [1]
查看完整版本: loadrunner Error 404