Forum Discussion
Microsoft Graph PowerShell SDK Module OneDrive Folder Permissions Assignment
Hi ShaneGibson,
thanks for your update.
The error message New-MgDriveItemPermission: A parameter cannot be found that matches parameter name 'RoleId' indicates that you are using an older version of the Microsoft Graph PowerShell SDK Module.
Please upgrade to the latest version of the module and try again.
To upgrade the Microsoft Graph PowerShell SDK Module, you can use the following PowerShell command:
Update-Module Microsoft.Graph.PowerShell.SDK
Please click Mark as Best Response & Like if my post helped you to solve your issue.
This will help others to find the correct solution easily. It also closes the item.
If the post was useful in other ways, please consider giving it Like.
Kindest regards,
Leon Pavesic
(LinkedIn)
I installed following this article which (See below link) and it only lists the Install and Update commands like this "Install-Module Microsoft.Graph" & "Update-Module Microsoft.Graph" and I have the latest version of that PS Module.
Can you send me the documentation link for where your recommended command "Update-Module Microsoft.Graph.PowerShell.SDK" came from, maybe I am using the wrong PS Module or looking in the wrong spot in the documentation for Microsoft Graph PowerShell Module?
https://learn.microsoft.com/en-us/powershell/microsoftgraph/installation?view=graph-powershell-1.0
- LeonPavesicOct 04, 2023Silver Contributor
Hi ShaneGibson,
thanks for your update, this documentation link you provided is correct.I apologize for the error in my previous response. The Update-Module Microsoft.Graph.PowerShell.SDK cmdlet does not exist.
To update the Microsoft Graph PowerShell SDK Module, you can use the following PowerShell command:
Update-Module Microsoft.Graph
This command will update the Microsoft Graph PowerShell SDK Module to the latest version, as well as any other Microsoft Graph modules that are installed on your system.
Please click Mark as Best Response & Like if my post helped you to solve your issue.
This will help others to find the correct solution easily. It also closes the item.If the post was useful in other ways, please consider giving it Like.
Kindest regards,
Leon Pavesic
(LinkedIn)