![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | I would like to use Win32_LogonSession but it is confusing to me. I would like to find out if a computer is in the locked computer state, is he or she currently using it or is it in the loin prompt waiting for some one to login. The problem is that I do not have access to te login script or AD. |
My System Specs![]() |
| | #2 (permalink) |
| | Re: I would like to use Win32_LogonSession but it is confusing to me. "freddy" <freddy@xxxxxx> wrote in message news:E18E435F-55F5-4B81-88D6-2D02527D990C@xxxxxx Quote: >I would like to find out if a computer is in the locked computer state, is >he > or she currently using it or is it in the loin prompt waiting for some one > to > login. The problem is that I do not have access to te login script or AD. class: http://www.microsoft.com/technet/scr.../dmlgvb01.mspx To retrieve the name of the user currently logged into the computer: http://www.microsoft.com/technet/scr.../dmlgvb02.mspx In both cases assign the NetBIOS name of the remote computer to the variable strComputer. If strComputer = "." that means the computer you are using. I don't know how to tell if the machine is in a locked state. -- Richard Mueller MVP Directory Services Hilltop Lab - http://www.rlmueller.net -- |
My System Specs![]() |
| | #3 (permalink) |
| | Re: I would like to use Win32_LogonSession but it is confusing to me. "freddy" <freddy@xxxxxx> wrote in message news:E18E435F-55F5-4B81-88D6-2D02527D990C@xxxxxx Quote: >I would like to find out if a computer is in the locked computer state, is >he > or she currently using it or is it in the loin prompt waiting for some one > to > login. The problem is that I do not have access to te login script or AD. state a workstation might happen to be in. That said, I have little knowledge of win32_logonsession, however, I'd suggest you write a script to display the values assigned to at least the more suggestive properties, like logontype, name, starttime, and status. If you cannot deduce what you are looking for from that, then perhaps it is not deduceable. /Al |
My System Specs![]() |
| | #4 (permalink) |
| | Re: I would like to use Win32_LogonSession but it is confusing to me. On Feb 18, 8:18*pm, "Al Dunbar" <aland...@xxxxxx> wrote: Quote: > "freddy" <fre...@xxxxxx> wrote in message > > news:E18E435F-55F5-4B81-88D6-2D02527D990C@xxxxxx > Quote: > >I would like to find out if a computer is in the locked computer state, is > >he > > or she currently using it or is it in the loin prompt waiting for some one > > to > > login. The problem is that I do not have access to te login script or AD. > That's no problem. Neither the logon script nor AD have any clue as to what > state a workstation might happen to be in. > > That said, I have little knowledge of win32_logonsession, however, I'd > suggest you write a script to display the values assigned to at least the > more suggestive properties, like logontype, name, starttime, and status. If > you cannot deduce what you are looking for from that, then perhaps it is not > deduceable. > > /Al Win32_ComputerSystem class and then, subsequently if there is a user logged on, check for a process named .SCR using the WIN32_Process WMI class. This would indicate that the system is locked, if your power management group policy requires locking after a given amount of time. Jim Jim |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| GPU-z confusing readout | Graphic cards | |||
| Confusing prompt for a [bool] value (V2 CTP) | PowerShell | |||
| Windows Firewall Confusing | Vista security | |||
| Confusing error on NetworkInformation | PowerShell | |||
| Confusing exception trapping behaviour | PowerShell | |||