Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $lockout = Get-WinEvent -FilterHashtable @{Logname='Security';ID=4740} -
- MaxEvents 10
- $lockoutevent =Get-EventLog -Log Security | where {$_.EventID -eq 4740}
- | Format-List -Property Index
- foreach ($event in $lockout)
- {
- $eventXML = $event | ConvertTo-XML
- $Array = @($event.RecordId)
- }
- for($i=0;$i -lt 0; $i++){
- Get-EventLog -Index $Array[$i] -LogName Security | Format-List -Property
- *
- }
Add Comment
Please, Sign In to add comment