Quantcast
Channel: Microsoft Online: SharePoint Online forum
Viewing all articles
Browse latest Browse all 10096

Add a Unified Group to a SharePoint Group using PowerShell

$
0
0

I've created a new Unified Group called "Students" using the New-UnifiedGroup cmdlet and that group is working just fine. Running theGet-MsolGroup cmdlet I can see that the group is created as a follows:

ExtensionData             : System.Runtime.Serialization.ExtensionDataObject
CommonName                :
Description               : Students
DirSyncProvisioningErrors :
DisplayName               : Students
EmailAddress              :Students@xxxxxxxx.onmicrosoft.com
Errors                    :
GroupType                 : DistributionList
IsSystem                  : False
LastDirSyncTime           :
Licenses                  : {}
ManagedBy                 :
ObjectId                  : 33490857-35d6-46ae-927e-b33974a30591
ProxyAddresses            : {SMTP:Students@xxxxxxxx.onmicrosoft.com}
ValidationStatus          : Healthy

I'd like to now add this new Unified Group to a SharePoint group using PowerShell. However, when I attempt to do so using theAdd-SPOUser cmdlet I get an error that the specified user cannot be found. I tried to use the email address, the ObjectId, and the display name and neither worked. I validated that I can add the Unified Group to the SharePoint Group via the browser and retrieving the details of the group I see the following, which suggests that using the ObjectId to add the Unified Group should work, but it doesn't:

DisplayName : Students
LoginName   : 33490857-35d6-46ae-927e-b33974a30591
IsSiteAdmin : False
IsGroup     : True
Groups      : {Team Site Visitors}

Is it just not yet possible to add Unified Groups to SharePoint Groups using the SPO cmdlets or am I just missing something simple? Is there an alternative approach such as a REST call that would work?


Gary Lapointe, Blog: http://blog.falchionconsulting.com/, Twitter: http://twitter.com/glapointe Aptillon Inc.: http://www.aptillon.com


Viewing all articles
Browse latest Browse all 10096

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>