From 824586a893733e8de4f3aca296109d91644ff4bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicol=C3=A1s=20D=C3=ADaz=20Lozano?= <90356833+ndlozano1990@users.noreply.github.com> Date: Mon, 26 Aug 2024 23:29:46 -0300 Subject: [PATCH] Update block-user-accounts-with-microsoft-365-powershell.md The -ObjectID parameter doesn't work for this command. -UserId is the correct one. --- .../block-user-accounts-with-microsoft-365-powershell.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/microsoft-365/enterprise/block-user-accounts-with-microsoft-365-powershell.md b/microsoft-365/enterprise/block-user-accounts-with-microsoft-365-powershell.md index 328d3ce7069..7e6cf201ea2 100644 --- a/microsoft-365/enterprise/block-user-accounts-with-microsoft-365-powershell.md +++ b/microsoft-365/enterprise/block-user-accounts-with-microsoft-365-powershell.md @@ -105,7 +105,7 @@ Update-MgUser -UserId $user.Id -BodyParameter $params To check the blocked status of a user account use the following command: ```powershell -Get-MgUser -ObjectID -Property "displayName,accountEnabled" | Select displayName, accountEnabled +Get-MgUser -UserId -Property "displayName,accountEnabled" | Select displayName, accountEnabled ``` ### Block multiple user accounts