QTP的Action模板

在QTP的安装目录,例如C:/Program Files/HP/QuickTest Professional/dat,创建一个名为ActionTemplate.mst的文件,文件中写模板内容,例如:
' -----------------------------------------------------------
' Author:
' Create Date:
' Revision:
' -----------------------------------------------------------

 

保存后,启动QTP,这样每次创建的Action都会包含模板中的内容。

除了在模板中写注释头信息外,还可以把一些每个Action都需要加载的函数或语句都写上,例如写入ExecuteFile语句加载VBS文件。

If you want to include one or more statements in every new action in your test, you can create an action template. For example, if you always enter your name as the author of an action, you can add this comment line to your action template. An action template applies only to actions created on your computer.

To create an action template:

Create a text file containing the comments, function calls, and other statements that you want to include in your action template. The text file must be in the structure and format used in the Expert View.
Save the text file as ActionTemplate.mst in your <QuickTest Installation Folder>/dat folder. All new actions you create contain the script lines from the action template.
Note: Only the file name ActionTemplate.mst is recognized as an action template.

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值