Register
: :
Login
Home
News
Forums
Scripts
User Groups
Resources
About
Forums
Search
Members
Unanswered
Active Topics
Forums
>
Using PowerShell
>
Working with .NET
Find out who logged on last to a computer
Last Post 11 Mar 2010 11:55 AM by
PoSherLife
. 1 Replies.
Sort:
Oldest First
Most Recent First
Prev
Next
You are not authorized to post a reply.
Author
Messages
Terry2win
New Member
Posts:39
04 Mar 2010 02:15 AM
Hello everybody. I've also posted the script in the "general powershell" section, but perhaps it belongs here instead?
I've got a script where I find out who is the logged on user for a specific PC. The script looks like this:
PS> Gwmi Win32_ComputerSystem -Comp "pcname"
This "script" works perfectly fine, but what if I want to (if there is no user logged on at the moment) find out which user that logged on last?
This information is stored in the registry and it's possible to extract it from there using .VBS so it should be possible with PowerShell too.
Any suggestions?
PoSherLife
Basic Member
Posts:364
11 Mar 2010 11:55 AM
double entry:
http://www.powershellcommunity.org/...fault.aspx
When at first you don't succeed
Step-Into
http://theposherlife.blogspot.com
http://www.jandctravels.com
You are not authorized to post a reply.
Using PowerShell
--General PowerShell
--Active Directory
--Exchange Server
--SharePoint
--SQL Server
--System Center
--Non-Microsoft Products
--Books, Tools, and Videos
--Working with .NET
--Peer Review
--Testing, Testing...
PowerShell Development
--Cmdlet Development
--PSDrive Provider Development
--Hosting the Shell
Looking Ahead
--Using PowerShell v2.0
--Developing for PowerShell v2.0
PowerShellCommunity.org
--Community Announcements and Assistance
--Completely Unrelated
--User Groups
--Community Business
----Suggestion Box
Forums
>
Using PowerShell
>
Working with .NET
Active Forums 4.3
Sponsored by Quest Software • SAPIEN Technologies • Compellent • Microsoft Windows Server 2008 R2