Log-in to Windows

为君一笑 提交于 2019-12-25 18:33:15

问题


I have a script using WinActivate(). I want to make sure the "Windows locked" scenario is taken care of.

I learned log-in/locked screen is just a dialog. Will it work if I send CTRL - ALT - DEL or does anyone have a working snippet for this scenario?


回答1:


The login screen runs on a completely separate desktop - no program from your normal user session can interact with the secure login desktop in any way. It is not "just a dialog" - it is a completely separated secure desktop.

What the AutoIT FAQ is saying is that you can use different commands that will still work when a window doesn't have focus. If you require the window to have focus for the script to work, you will have to wait until the computer is unlocked. You can set up a scheduled event to run when the workstation is logged on or unlocked, and could configure it to only run if the script isn't already running. You could also rewrite your script using the commands referenced in the linked FAQ, so that the script runs even if it's not on the actively visible desktop.



来源:https://stackoverflow.com/questions/16901298/log-in-to-windows

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!