While working on Dynamics 365 Portal, We all have observed an error message is displayed like below when an error occurred in Portal Add-on.
\”We\’re sorry, but something went wrong. Error ID #\”
\”An unknown failure has occurred. Error ID # \”
But they\’re quite unclear, so users cannot take any action based on this message. GUID doesn\’t help.
If there\’s certain contact such as e-mail address of Portal admin, the error message should contain this information and suggest to contact to admin.
These type of errors usually comes when any CRM Plugins/Workflows throw the Server-Side error while processing the Portal requests.
Currently, Microsoft has not provided any direct way to customize this error message. Though a lot of people submitted their ideas on Microsoft Idea Portal to addon this feature in upcoming portal releases.
// You just need to Change the error message only
var errorMessage = \”We\’re experiencing an internal server problem. Please try again later or contact email@example.com\”;