Hello
The error code 2150040321 you’re encountering in Outlook is typically related to sign-in issues. Here are some potential solutions:
1.Reset the WAM (Web Account Manager): This error can be caused by security software impacting the WAM plug-in (AAD.BrokerPlugin). You can try to repair WAM by running the following commands in PowerShell:
Add-AppxPackage -Register "$env:windir\SystemApps\Microsoft.AAD.BrokerPlugin_cw5n1h2txyewy\Appxmanifest.xml" -DisableDevelopmentMode -ForceApplicationShutdown
Add-AppxPackage -Register "$env:windir\SystemApps\Microsoft.Windows.CloudExperienceHost_cw5n1h2txyewy\Appxmanifest.xml" -DisableDevelopmentMode -ForceApplicationShutdown
2.Check User Profile Management Practices: If user profile data is being roamed, it can cause identity and authentication data components to be in a bad state. Make sure that the content of the following folders and registry keys never leaves the device under any condition:
%localappdata%\Packages\Microsoft.AAD.BrokerPlugin_cw5n1h2txyewy
%localappdata%\Packages\Microsoft.Windows.CloudExperienceHost_cw5n1h2txyewy
%localappdata%\Packages\<any app package>\\AC\\TokenBroker
%localappdata%\Microsoft\TokenBroker
HKEY_CURRENT_USER\SOFTWARE\Microsoft\IdentityCRL
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\AAD
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WorkplaceJoin
3.Clear OneAuth and IdentityCache Folders: Close all Microsoft applications, navigate to C:\Users<yourusername>\AppData\Local\Microsoft, cut and paste the OneAuth and IdentityCache folders out of the Microsoft folder and onto your desktop. Then, relaunch Outlook and sign in.
These solutions require administrative privileges. If you’re not an administrator, you may need to contact your IT department for assistance.