There can be situations when you need to schedule your QTP scripts so that they can run when you are not present in front of you PC. I will show you a demo below -
1) Create a .vbs fild to launch QTP with requiresd settings, add-ins etc.\\
Here is a sample vbs code
Set App = CreateObject("QuickTest.Application")
App.Launch
App.Visible = True
App.WindowState = "Maximized"
App.ActivateView "ExpertView"
App.open "C:\Program Files\Mercury Interactive
\QuickTest Professional\Tests\Test1", False
'Opens the test in editable mode
2) OK, for the first timers. Create a sample QTP test and save it as Test1 at the location above. Copy the code into notepad and name the file as testing.vbs3) Now we will automate the opening of vbs file through windows scheduyler. Go to Start > Control Panel > Schedule Tasks > Click Add Schedule Tasks Click Next on the Screen
4) Click Browse and select the .vbs file you just created. You will ge this screen.
5) Give a name to the task and select the frequence for performing the
given tasks. For this demo we will select "One time only"
6) Select Start Time and Start Date. For this demo, select Start Time as current time+5 mins and Start date as today date.
7) Next Screen Enter "UserNAme", "Password" and "Confirm Password"
Click Next and you should get this screen.
8) Click on Finish, you're done.