ruudmens / LazyAdmin

SysAdmin scripts for you to use.
MIT License
606 stars 216 forks source link

Not all users are being gathered #7

Closed Cyclone47 closed 2 years ago

Cyclone47 commented 2 years ago

When using this script (tested in 3 different tenants with global admin) some users are not being exported properly. image

Any clue how to resolve this? I tried troubleshooting it a lot but can't seem to find why it's doing this.

Get-EXOMailbox -Identity $identity -Properties GrantSendOnBehalfTo, ForwardingSMTPAddress | select UserPrincipalName, DisplayName, PrimarySMTPAddress, RecipientType, RecipientTypeDetails, GrantSendOnBehalfTo, ForwardingSMTPAddress

  This seems to be going well; however the function Get-AllMailboxPermissions shows many empty lines

image

Cyclone47 commented 2 years ago

I feel like it might have something to do with the inbox name as these tenants are Swedish.

Ruud-Mens commented 2 years ago

Can you check the calendar folder name with: Get-mailbox -Identity <YOUR-EMAIL-ADDRESS> | Get-MailboxFolderStatistics -FolderScope calendar | sort-object Name |ft Identity,Name

Cyclone47 commented 2 years ago

@Ruud-Mens Getting this as output image

Ruud-Mens commented 2 years ago

If you change line 114 to Kalender it should work.

Cyclone47 commented 2 years ago

If you change line 114 to Kalender it should work.

Thanks, I'll try!