How to remove and Set AD Login Scripts for all users

Import-module ActiveDirectory

Get-ADUser -Filter * | Set-ADUser -Clear scriptPath

How to Set

Get-ADUser -Filter * -SearchBase “OU=Marketing,DC=martinsblog,DC=local” | Set-ADUser –scriptPath “\\dc01\netlogon\myscript.bat”

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...