QTP Tips – Part 1
1. Can I change the Active Screen page which is shown on every new test?
This page can be changed to be any valid HTML page. The page can be located either locally or on the network.
For example, if you want your entire organization to view the same Active Screen page when they open QTP, you should open the NewTest.inf file located under the dat\snapshots directory of QTP and set the next line:
FileName1=<any full path to an HTML file>
2. How to create an action template?
You can create a template action script that will be used on every new action that is created. You can use this, for example, to add a header comments to each action.
To create the template action you should create a text file with the name ActionTemplate.mst and place it under QTP dat folder.
3. How to pass parameters when calling actions?
You can pass information between actions in several ways:
1. Using the new Action Parameters feature in Quick Test 8.0
2. Putting the variable in the data table and then accessing this data table from the called action.
3. Defining the variable as an environment variable that can be accessed from the entire test.
4. How to configure the report to show only error (by default)?
You can configure the report to show only error by default by adding the following section to the QTReport.ini file (located under QTP bin directory).
ReportAppDefaultFilter=1 # for error only
ReportAppDefaultFilter=3 # shows all messages (default)
5. How to use Environment variable?
QuickTest supports using environment variables. Environment variables can be either system variables or user defined variables.
You can define the user defined variables in an external file which will be read by QuickTest when it will be launched.
Read QTP Tips – Part 2
See the Using Environment Variables.