I have console app running in background under Assigned Access (Windows 10's Kiosk Mode). By command from main UWP-app it should logoff current user. I've tried 2 ways to do this:
- WinAPI function
ExitWindowsEx(0, 0)
Process.Start("shutdown /l /f")
Both works well if current user has password. But if user has no password, Windows re-login immediately after logout. Is there a way to avoid re-login?
UPDATE:
Looks like LockWorkStation
does not working too. May be it for security reasons?