QC & QTP How to schedule a recurring test set

Problem – Quality center’s issue with running periodic test sets
This has been a long standing issue with me and Quality Center. You can use QC to schedule a testset to run at a given time but the issue is when you need to have a testset run at a recurring time — say every day at 5:00 am.
Solution
To get testsets to run periodically you can use Vbscript with QC’s OTA API and Windows scheduler.
VBScript code needed to run test set in QC
First you need to setup a VBScript that calls the Quality Center’s testset that you want to run:
set tdc = createobject("TDApiOle80.TDConnection")
tdc.InitConnectionEx "http://qcURL/qcbin/"
tdc.login "yourUserName","yourPassword"
tdc.Connect "yourDomain","yourProject"
Set objShell = CreateObject("WScript.Shell")
Set TSetFact = tdc.TestSetFactory
Set tsTreeMgr = tdc.TestSetTreeManager
Set tsFolder = tsTreeMgr.NodeByPath("RootFormal TestsYourTestDirectory")
Set tsList = tsFolder.FindTestSets("Your TestSet name. This is case sensitive!")
Set theTestSet = tsList.Item(1)
Set Scheduler = theTestSet.StartExecution("")
Scheduler.RunAllLocally = True
Scheduler.run
Set execStatus = Scheduler.ExecutionStatus
Do While RunFinished = False
execStatus.RefreshExecStatusInfo "all", True
RunFinished = execStatus.Finished
Set EventsList = execStatus.EventsList
For Each ExecEventInfoObj in EventsList
strNowEvent = ExecEventInfoObj.EventType
Next
For i= 1 to execstatus.count
Set TestExecStatusobj =execstatus.Item(i)
intTestid = TestExecStatusobj.TestInstance
Next
Loop
Window’s Scheduled Tasks for Running Tests
Next you need to setup the windows scheduler to run at the desired time. See video for step by step instructions.
RunTestSet.exe – Another option
If you do not want to create your own VBScript to run your test sets you can also try an unsupported tool from HP – RunTestSet.exe.
RunTestSet is a VC++ console application that you can send command line options to in order to run a QC a test set. You can download RunTestSet and its documentation from HP or from https://testguild.com/downloads
Joe Colantonio is the founder of TestGuild, an industry-leading platform for automation testing and software testing tools. With over 25 years of hands-on experience, he has worked with top enterprise companies, helped develop early test automation tools and frameworks, and runs the largest online automation testing conference, Automation Guild.
Joe is also the author of Automation Awesomeness: 260 Actionable Affirmations To Improve Your QA & Automation Testing Skills and the host of the TestGuild podcast, which he has released weekly since 2014, making it the longest-running podcast dedicated to automation testing. Over the years, he has interviewed top thought leaders in DevOps, AI-driven test automation, and software quality, shaping the conversation in the industry.
With a reach of over 400,000 across his YouTube channel, LinkedIn, email list, and other social channels, Joe’s insights impact thousands of testers and engineers worldwide.
He has worked with some of the top companies in software testing and automation, including Tricentis, Keysight, Applitools, and BrowserStack, as sponsors and partners, helping them connect with the right audience in the automation testing space.
Follow him on LinkedIn or check out more at TestGuild.com.
Related Posts
Look, I’ve been doing this testing thing for over 25 years now. I first wrote about the AI “three waves” […]
What’s New in Low-Code/No-Code Testing for 2026 A lot had changed on the The low-code/no-code testing space and it has […]
I want to share an update on one of my favorite exploratory testing tools that just keeps getting better. I […]
Here is my list of the best open source API testing tools for 2025 Application Programming Interface (API) testing is […]



