+ 1

How to set AD user account expiration date in powershell using only samaccount name

17th Jun 2022, 2:15 PM
Kavitha AV
1 Antwort
0
$Username = "samaccountname" $ExpirationDate = (Get-Date).AddDays(1) Set-ADUser -Identity $Username -AccountExpirationDate $ExpirationDate
14th Apr 2023, 6:20 AM
Serhii Dubynskyi
Serhii Dubynskyi - avatar