Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

Edit in excel stopped working with on prem v14

Posted on by 49

My BC v14 on prem edit in excel was working and has stopped now with the following error

9002326 - [2023-01-17 17:34:33Z]: AADSTS9002326: Cross-origin token redemption is permitted only for the 'Single-Page Application' client-type. Request origin: 'az689774.vo.msecnd.net'.
Trace ID: ef3111d0-0f52-4be2-b793-1f1c9f637f00
Correlation ID: 01760714-ba8d-4bde-9a56-9b7d6364bc3d
Timestamp: 2023-01-17 17:34:33Z - Correlation ID: 01760714-ba8d-4bde-9a56-9b7d6364bc3d - Trace ID: ef3111d0-0f52-4be2-b793-1f1c9f637f00

I also get this when attempting the sign in within excel using the excel add-in

Error encountered Network request failed: If the browser threw a CORS error, check that the redirectUri is registered in the Azure App Portal as type 'SPA' | Network client threw: Failed with status 400 | Attempted to reach: https://login.microsoftonline.com/0bed2171-b39d-4a1c-a46e-df0414171bb0/oauth2/v2.0/token
The manifest in Azure was setup as web and I changed it to Spa but this has not helped.

Looks like something has changed but as far as I am aware nothing has been changed with the BC settings. Is there something MS have changed?

I have googled this but others with this issue are mentioning third party apps having this issue and does not look like the solutions apply to on prem BC

  • Suggested answer
    Marco Mels Profile Picture
    Marco Mels on at
    RE: Edit in excel stopped working with on prem v14

    Hello,

    You should have this in the Edit in Excel Azure AD app registration:

    {

       "url": "az689774.vo.msecnd.net/.../*",

       "type": "Spa"

    }

    This is described here:

    learn.microsoft.com/.../configuring-excel-addin

    And also the following two settings should be set to true:

    "oauth2AllowIdTokenImplicitFlow": true,

    "oauth2AllowImplicitFlow": true,

    Hope it helps. If not, feel free to raise it to Microsoft support via your partner or CSP.  Related to the cases I worked on in all releases of NAV / BC, it is 99.9% due to configuration issues (which are usually hard to find, but we are here to find the needle in the haystack saving you the time and efforts).

    Thank you.

  • EssexRocks Profile Picture
    EssexRocks 49 on at
    RE: Edit in excel stopped working with on prem v14

    Marco

    Thanks for the reply.

    I have this at the moment az689774.vo.msecnd.net/.../*

    I have a warning at the top of the Web redirect URLs saying I should migrate (This app has implicit grant settings enabled. If you are using any of these URIs in a SPA with MSAL.js 2.0, you should migrate URIs) and in this it shows both the urls I have the az689774.vo.msecnd.net/.../* and my BC external url https://......:8080/bc140/

    Do I migrate both?

  • Suggested answer
    Marco Mels Profile Picture
    Marco Mels on at
    RE: Edit in excel stopped working with on prem v14

    Hello,

    You indeed need to change the platform in the Excel Azure AD app registration to Spa for the "az689774.vo.msecnd.net/.../*"

    After that it should work.

    We sometimes see that the Azure AD app registration shows correct settings but in Azure itself is still running with the cached settings. Recreating the Azure AD app may also work. Also for the SignInAudience, use AzureADMultipleOrgs or AzureADMyOrg. Don't choose the one with XBOX and personal accounts which is an option as well.

    Thank you.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans