初学描述性编程求助!
SystemUtil.Run "iexplore.exe","","","open"Browser("title:=自定义您的位置").Navigate "http://www.google.com/"
为什么不行,应该怎么写 You should tell us what error you met first, then we can investigate where the problem should be.
But I think your problem shoud be not enough attribute to allow QTP to recognize the UI object unique. 我就是想让系统打开IE,然后跳转到google,应该怎么写? SystemUtil.Run "iexplore.exe","","","open"
Browser("title:=.*").Navigate "http://www.google.com/"
这样应该就好了 SystemUtil.Run "iexplore.exe","","","open"
url=".*"
Browser("title:="&url).Navigate( "http://www.google.com/")
试过了,没问题 描叙性编程,必须取得唯一值。title总是唯一的 原帖由 kou_dou 于 2008-11-26 11:29 发表 http://bbs.51testing.com/images/common/back.gif
SystemUtil.Run "iexplore.exe","","","open"
url=".*"
Browser("title:="&url).Navigate( "http://www.google.com/")
试过了,没问题
怎么不行?
提示:General run error.
Line (18): "Browser("title:="&url).Navigate( "http://www.google.com/")". 按照楼上两位的试了试,运行结果没有显示Fail,但是IE也没有跳转到google,附图 奇怪,我这儿出错 TEST_HUAN ,你把浏览器窗口都关掉,再试试 SystemUtil.Run "iexplore.exe","http://www.google.com/",3 原帖由 没有蛀牙 于 2008-11-26 15:34 发表 http://bbs.51testing.com/images/common/back.gif
SystemUtil.Run "iexplore.exe","http://www.google.com/",3
这是直接打开吧,要想跳转到某个网页怎么写? 加上等待时间就好了
SystemUtil.Run "iexplore.exe","","","open"
wait 5
Browser("title:=.*").Navigate "http://www.google.com/" 原帖由 没有蛀牙 于 2008-11-26 15:34 发表 http://bbs.51testing.com/images/common/back.gif
SystemUtil.Run "iexplore.exe","http://www.google.com/",3
我用的是QTP9.5, 除了这一个可以直接link到google上,其他的都出错,都说找不到object: tracyd,提示的意思是说匹配到了多于一个的对象,也就是说你打开了一个以上的IE窗口,你把IE都关掉应该就可以了。
我又试了试,的确是因为我一直开着51testing.com的网页
所有的网页都关掉就成功了。谢谢!
页:
[1]