Quantcast
Channel: TechNet Blogs
Viewing all articles
Browse latest Browse all 36188

Enable Administrator to access all users' OneDrive for Business

$
0
0

Download, install and run the SharePoint Online Management Shell
http://www.microsoft.com/en-us/download/details.aspx?id=35588

Replace <domain> with your domain name and <tenant> with your SharePoint Online tenant name.

$objCreds = Get-Credential

Connect-SPOService -Url https://<tenant>.sharepoint.com -credential $objCreds

$colUsers = Get-SPOUser -Site https://<tenant>-my.sharepoint.com/ | Where-Object {$_.LoginName -like '*<domain>.com*'}

$colUsers = $colUsers.LoginName | ForEach-Object { $_.TrimEnd("<domain>") } | ForEach-Object { $_.TrimEnd("@") }

$colUsers | ForEach-Object { Set-SPOUser -Site https://<tenant>-my.sharepoint.com/personal/"$_"_<domain>/ -LoginName company_administrator@<domain>.com -IsSiteCollectionAdmin $true }


Viewing all articles
Browse latest Browse all 36188

Trending Articles



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