cancel
Showing results for 
Search instead for 
Did you mean: 

"How can I use the Task Scheduler to unlock my PC?"

SOLVED
Highlighted
Contributor

"How can I use the Task Scheduler to unlock my PC?"

So I read Smartbear's documentation regarding "Schedule Automated Tests" using the Task Scheduler in Windows 10 . As long as I do as they say and NOT lock my PC (because I'm testing the GUI) it works fine. 

 

BUT - my security team requires me to lock my PC every night before heading home.  I would like to set up a task to unlock my PC one minute before I have the task kick off the automated test I need to run every day which should  finish right about the time I usually hit my desk.

 

Anyone know how to do that?  Web searches have been fruitless, and the only other documentation on Smartbear's site is in regard to running on "Locked Computers"  which is not what I want to do.

1 ACCEPTED SOLUTION

Accepted Solutions
Contributor

Re: "How can I use the Task Scheduler to unlock my PC?"

Gang - Thank you for your responses.  Between your comments and what SmartBear support sent me, sounds like my best option is to use one of our VM's.  Thank you for your time.

View solution in original post

3 REPLIES 3
Contributor

Re: "How can I use the Task Scheduler to unlock my PC?"

Try to execute cmd line like "tscon 2 /dest:console" where "2" is your user session ID.

It should switch running user session to console session and your tests could run.

https://support.smartbear.com/testcomplete/docs/testing-with/running/scheduling.html?q=tscon

Community Hero

Re: "How can I use the Task Scheduler to unlock my PC?"

Hi,

 

As a not verified idea: You may consider to use the RebootAndContinue() method if your test account is granted necessary permissions.

(Though usually it is more easy and reliable to have a dedicated not locked machine (with disconnected monitor, for example).)

 

Regards,
Alex
[Community Expert Group]
____
[Community Expert Group] members are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Postings made by [Community Expert Group] members
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
[Community Expert Group] signature is used with permission by SmartBear Software.
http://smartbear.com/forums/f83/t86934/community-experts/
================================
Contributor

Re: "How can I use the Task Scheduler to unlock my PC?"

Gang - Thank you for your responses.  Between your comments and what SmartBear support sent me, sounds like my best option is to use one of our VM's.  Thank you for your time.

View solution in original post