Today I got the following “Invalid Organization value” error when trying to run Start-HistoricalSearch and Get-HistoricalSearch in Office 365.
Start-HistoricalSearch -ReportType MessageTrace -ReportTitle “02-2019” -NotifyAddress firstname.lastname@example.org -StartDate 02/01/2019 -EndDate 03/01/2019 -RecipientAddress email@example.com
start-HistoricalSearch : Invalid Organization value.
At line:1 char:1
It appears this error occurs when I first load Microsoft.Exchange.Management.PowerShell.E2010 with cmdlet:
and afterwards try to connect to MSOL:
The Add-PSSnapin was a mistake, so it was easy for me to fix. But if you encounter this same error and you need both PSSnapin and Module, try to swap them.