QTP/UFT support tip: How change mouse replay type
There are scenarios were a scritp is replaying some actions do not occur as expected. Often changing the Web add-in's replay type from event to mouse, or vise versa, will help
To change the event type for the entire script follow these steps:
- From the Tools menu, select Options.
- Select Web.
- Click Advanced.
- Under Replay type in the Run settings, select Event or Mouse, as necessary.
- Click OK to close the dialogs.
Also you can made this change by code in case that the change wants to be applied to spefic llines of code.
To set QuickTest Professional to replay by mouse clicks, use:
Setting.webpackage("ReplayType") = 2 'Mouse
To set QuickTest Professional to replay by Web events, use:
Setting.webpackage("ReplayType") = 1 'Event
You can get the current replay mode using the following syntax:
orig = Setting.webpackage("ReplayType")
Note: The Opinions expressed in my post are mine alone, and do not reflect the opinions of my employer. No warranties express or implied for any answered posted.