wsnyder
Board Regular
- Joined
- Sep 23, 2018
- Messages
- 224
- Office Version
- 365
- Platform
- Windows
Hi all,
Has anyone use Powershell to send a list of user access to csv file?
My script is creating the csv file, but there are only 3 odd characters in cell A1.
Has anyone use Powershell to send a list of user access to csv file?
My script is creating the csv file, but there are only 3 odd characters in cell A1.
Code:
>> $Workspaces = Get-PowerBIWorkspace -All
>>
>> $Workspaces |
>> ForEach-Object {
>> $Workspace = $_.name
>> foreach ($User in $_.Users) {
>> [PSCustomObject]@{
>> Workspace = $Workspace
>> User = $User.UserPrincipalName
>> }
>> }
>> } | Export-CSV "C:\\PowerBIGroupMembers.csv" -NoTypeInformation -Encoding UTF8