Home > Software engineering >  VB how to judge whether a system is cancelled after login
VB how to judge whether a system is cancelled after login

Time:11-12

VB how to judge whether a system boot after login or logout after login

CodePudding user response:

This how do ah, bad judgement, might determine the boot time, see if leave the machine time is close, but it also proves nothing,

CodePudding user response:

Judge winlogon process. Exe start time (start time) for process and system startup time gap,
The current time - boot after the GetTickCount=system startup time,
System startup time can also be obtained from the WMI,

But these are dependent on the operating system time mechanism, is not stable and reliable,
User logout behavior is similar to restart, normally don't need to care about the cancellation, just when the user to restart the computer,
  • Related