Lock the system

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jochen Berger

    Lock the system

    Moin!

    Maybe I'm blind, but I couldn't find it in the documentation. How do I
    lock the system / machine? I want to lock it, as if the user would've
    pressed Ctrl+Alt+Del, and then selected "Lock computer".

    TIA

    Jochen

    *** Sent via Developersdex http://www.developersdex.com ***
  • Nicholas Paldino [.NET/C# MVP]

    #2
    Re: Lock the system

    Jochen,

    In order to do this, you will have to call the LockWorkStation API
    function through the P/Invoke layer. The declaration should be on
    http://www.pinvoke.net.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - mvp@spam.guard. caspershouse.co m

    "Jochen Berger" <berger9@web.de > wrote in message
    news:uQromFbvFH A.2960@tk2msftn gp13.phx.gbl...[color=blue]
    > Moin!
    >
    > Maybe I'm blind, but I couldn't find it in the documentation. How do I
    > lock the system / machine? I want to lock it, as if the user would've
    > pressed Ctrl+Alt+Del, and then selected "Lock computer".
    >
    > TIA
    >
    > Jochen
    >
    > *** Sent via Developersdex http://www.developersdex.com ***[/color]


    Comment

    Working...