microsoft / AL

Home of the Dynamics 365 Business Central AL Language extension for Visual Studio Code. Used to track issues regarding the latest version of the AL compiler and developer tools available in the Visual Studio Code Marketplace or as part of the AL Developer Preview builds for Dynamics 365 Business Central.
MIT License
718 stars 242 forks source link

Error on "Verify Registration" at "Email Microsoft Entra application registration" #7774

Closed SidlyarSergii closed 2 weeks ago

SidlyarSergii commented 2 weeks ago

1. Describe the bug We installed BC 24.2 W1 On-Prem. We are trying to configure the mailing functionality in Business Central but receiving the following error while clicking "Verify Registration" action on the "Email Microsoft Entra application registration" page. image

2. To Reproduce Steps to reproduce the behavior:

  1. Install BC 24.2 W1 On-Prem

  2. Register Azure app in the Azure portal and provide App permissions according to this article https://learn.microsoft.com/en-us/dynamics365/business-central/admin-how-setup-email#set-up-email-for-business-central-on-premises image

  3. Create a Client Secret for the registered Azure app image

  4. Open BC Web Client and search for "Email Microsoft Entra application registration" in Tell Me image

  5. Specify Client ID, Client Secret and Redirect URL from the registered Azure App in the opened page: image

  6. Click "Verify Registration" action

3. Expected behavior Authentication should be successfully verified image

4. Actual behavior An error "A DotNet variable has not been instantiated. Attempting to call Microsoft.Dynamics.Nav.Runtime.ALAzureAdCodeGrantFlow.LastErrorMessage in CodeUnit OAuth2Impl: GetLastErrorMessage" is shown image

Additional Info: We tried to do the same steps for BC22.5 On Prem and everything works fine We tried to do the same steps for BC24.1 On Prem and received the same error We googled this issue and found that other users have similar problem: https://www.dynamicsuser.net/t/error-with-bc240-email-setup-microsoft-app-registration/85281

thloke commented 2 weeks ago

Hi, this issue is out of scope of for this repository. You should do one of the following:

As a reminder, this repository only handles issues to do with the compiler or VSCode development experience for AL.