Advertisement
Guest User

Untitled

a guest
Feb 14th, 2016
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. $AppliedGPOs = $(Get-WmiObject -Namespace 'ROOT\RSOP\Computer' -Class RSOP_GPLink -Filter "AppliedOrder <> 0" | Select @{n='GPO';e={$_.GPO.Replace("RSOP_GPO.","")}} | Select -ExpandProperty GPO)
  2. Get-WmiObject -Namespace 'ROOT\RSOP\Computer' -Class 'RSOP_GPO' -Filter $AppliedGPOs[0]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement