issue with Set-ListPermissions

Oct 7, 2016 at 4:41 AM

A big thanks for this product, it is very good!

I am having issue with Set-ListPermissions. Attempting to use it on our SharePoint Online instance.

When I run this:
Set-ListPermissions -groupname "group_123" -listname "PSTESTLIST" -roleType "Reader"

I get this:
Exception calling "Add" with "2" argument(s): "The 'principal' argument cannot
be null.
Parameter name: principal"
At line:71 char:9
  • $ra = $list.RoleAssignments.Add($group, $rdb)
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    • CategoryInfo : NotSpecified: (:) [], MethodInvocationException
    • FullyQualifiedErrorId : ArgumentNullException
Can you please help me with this?