Skip to content

Instantly share code, notes, and snippets.

@lukegackle
Last active March 30, 2022 13:03
Show Gist options
  • Save lukegackle/e629a211e1ea2166f5349daf2c793548 to your computer and use it in GitHub Desktop.
Save lukegackle/e629a211e1ea2166f5349daf2c793548 to your computer and use it in GitHub Desktop.
This script deletes any instance of the reg key "0102663e" as advised by MS Support, this key can become corrupted, leading to emails not syncing for shared mailboxes.
#-----------------------------------------------------------
# Fix for Shared Mailboxes Not Syncing Outlook
#
# This script deletes any instance of the reg key "0102663e"
# as advised by MS Support, this key can become corrupted,
# leading to emails not syncing for shared mailboxes.
#
# MS bug log:
# https://admin.microsoft.com/#/servicehealth/history/:/alerts/EX316072
# https://support.microsoft.com/en-us/office/shared-mailbox-is-not-automatically-refreshing-for-new-email-in-outlook-94b97f45-c57c-45f3-9716-f3f6bec47c73
#
# Script written by Luke Gackle 9/3/2022
#-----------------------------------------------------------
$OutlookProfilePath = "HKCU:\SOFTWARE\Microsoft\Office\16.0\Outlook\Profiles\Outlook\"
cd $OutlookProfilePath
$searchText = "0102663e"
Get-ChildItem . –rec –ea SilentlyContinue | foreach {
if((get-itemproperty -Path $_.PsPath) -match $searchText)
{
$key = $_.PsPath
$keyinstance = (Get-ItemProperty -Path $key -Name $searchText)
Write-Host $keyinstance.PSPath
Write-Host "Deleting key..."
Remove-ItemProperty -Path $key -Name $searchText
Write-Host "Key deleted." -ForegroundColor Green
}
}
Read-Host -Prompt "Press any key to exit..."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment