How to lock the PC after automatically running Quick Test Professional scripts?
Being a graphical interface record-playback automation tool, Quick Test Professional makes wonders enabling the professionals to work with any web, java or windows client application. Ranging from testing standard web pages, web objects, and ActiveX controls. Quick Test Professional (Quick Test Professional) also enables to test Java applets and applications and multimedia objects on Applications as well as standard Windows applications, Visual Basic 6 applications and .NET framework applications…
Interactive Testing tool
Quick Test Professional is a revolutionary testing tool that is powered with Mercury Interactive Functional Testing. For instance, Mercury QTP provides the industry’s best solution for functional test and regression test automation – addressing every major software application and the environment. This next-generation automated testing solution deploys the concept of Keyword-driven testing to radically simplify test creation and maintenance. Unique to QTP’s Keyword-driven approach, test automation experts have full access to the underlying test and object properties, via an integrated scripting and debugging environment that is round-trip synchronized with the Keyword View.
The most important advantage of Automation Testing is that Scripts are run in an unattended mode. It allows the tester to prepare the batch of scripts and leave their homes. Once the batch scripts are successfully completed running, no matter even if it passes or even get failed, the PC is unlocked inviting others to view your secret project related data. Sometimes, this could pose a security issue or efficiently issue in an organization. However, it can become an extremely devastating issue in a case of a company having Finance or Banking related projects, having top most concern for the security of its data. Here are some simple tricks to lock the PC once the scripts are over.
You can use the following Quick Test Professional Script to Lock your PC :
Set obj = CreateObject("WScript.Shell")
sCmnd = "%windir%\SYSTEM32\rundll32.exe user32.dll,LockWorkStation"
obj.Run sCmnd, 0, False
The above Quick Test Professional Script will lock your PC automatically. Moreover, I will suggest you create this Script as a separate Script and call this Script lastly in your batch. This will solve the purpose.
Find a course provider to learn QTP
Java training | J2EE training | J2EE Jboss training | Apache JMeter trainingTake the next step towards your professional goals in QTP
Don't hesitate to talk with our course advisor right now
Receive a call
Contact NowMake a call
+1-732-338-7323Enroll for the next batch
QTP Training coures and Certification
- Jul 30 2025
- Online
QTP Training coures and Certification
- Jul 31 2025
- Online
QTP Training coures and Certification
- Aug 1 2025
- Online
Related blogs on QTP to learn more

Why QTP is the best functional/regression testing tool?
Quick Test Professional (QTP) is nothing but a simple and Windows based software application that is used as a testing tool to check the applications developed for web and desktops. Software testers learn QTP

Seamless testing with the help of QTP!
QTP (Quick Test Professional) is a tool for testing the functionality of software as an automated process. As soon the script is developed, software tester can seamlessly perform this automated functionality testing and generate the report.

QTP- Is It The Right Choice For You?
QTP is the acronym of Quick Test Professional. It is a product of Hewlett Packard (HP). QTP helps testers to execute an automated functional testing flawlessly without examining after the completion of script development.

How To Manage Test Data in QTP Test Scripts?
Well, QTP is the acronym of Quick Test Professional. It is an automation testing tool. In 2011, QTP was released as a product under the UFT (Unified functional Test Software). QTP is one of the popular automation tools available in the market. The be
Latest blogs on technology to explore

Understanding Artificial Intelligence: Hype, Reality, and the Road Ahead
Explore the reality of Artificial Intelligence (AI) — its impact, how it works, and its potential risks. Understand AI's benefits, challenges, and how to navigate its role in shaping industries and everyday life with expert training programs

How Much Do Healthcare Administrators Make?
Discover how much healthcare administrators make, the importance of healthcare, career opportunities, and potential job roles. Learn about salary ranges, career growth, and training programs with Sulekha to kickstart your healthcare administration jo

How to Gain the High-Income Skills Employers Are Looking For?
Discover top high-income skills like software development, data analysis, AI, and project management that employers seek. Learn key skills and growth opportunities to boost your career.

What Companies Expect from Product Managers in 2025: Skills, Tools, and Trends
Explore what companies expect from Product Managers in 2025, including essential skills, tools, certifications, and salary trends. Learn how to stay ahead in a rapidly evolving, tech-driven product management landscape.

Breaking Into AI Engineering: Skills, Salaries, and Demand in the US
Discover how to break into AI engineering with insights on essential skills, salary expectations, and rising demand in the US. Learn about career paths, certifications, and how to succeed in one of tech’s fastest-growing fields.

Cybersecurity Training: Powering Digital Defense
Explore top cybersecurity training programs in the USA to meet rising demand in digital defense. Learn about certifications, salaries, and career opportunities in this high-growth field.

Why Pursue Data Science Training?
Empower your career in a data-driven world. Learn why data science training is crucial for high-demand jobs, informed decisions, and staying ahead with essential skills.

What Does a Cybersecurity Analyst Do? 2025
Discover the vital role of a Cybersecurity Analyst in 2025, protecting organizations from evolving cyber threats through monitoring, threat assessment, and incident response. Learn about career paths, key skills, certifications, and why now is the be

Artificial intelligence in healthcare: Medical and Diagnosis field
Artificial intelligence in healthcare: Medical and Diagnosis field

iOS 18.5 Is Here: 7 Reasons You Should Update Right Now
In this blog, we shall discuss Apple releases iOS 18.5 with new features and bug fixes