12Knocksinna / Office365itpros

Office 365 for IT Pros PowerShell examples
MIT License
1.28k stars 567 forks source link

Issue 01 #41

Closed vitusq closed 2 years ago

vitusq commented 2 years ago

Hi,

As soon as this script is executed, it display the following errors:

Attempted to divide by zero. At C:\temp\test.ps1:85 char:1

Statistics

Guest Accounts 0 Active Guests 0 Audit Record found 0 Active on Email 0 InActive Guests 0 Percent inactive guests Cannot index into a null array. At C:\Temp\test.ps1:95 char:1

Guests from domains

The output file containing detailed results is in c:\temp\GuestActivity.csv

12Knocksinna commented 2 years ago

Obviously the calls to find information didn't succeed. Your account probably doesn't have the right permissions (or if it's a Graph-based script, the underlying registered app doesn't have the right permissions). Can you check those things?