Skip to Content

Solved: How do I fix ASP.net Core Development Mode error occurred while processing your request

Question/Problem Description

In ASP.net Core the following code inserts bookmarks into a Word document using Syncfusion and then exports the Word doc in the browser. This works well when the project is debugged but does not work after the project is published on Azure.

The error below is shown on the web page:

Error.
An error occurred while processing your request.
Development Mode
Swapping to Development environment will display more detailed information about the error that occurred.
Development environment should not be enabled in deployed applications, as it can result in sensitive information from exceptions being displayed to end users. For local debugging, development can be enabled by setting the ASPNETCORE_ENVIRONMENT environment variable to Development, and restarting the application.

How can I test the code once published on Azure?

Solution

Set the DOTNET_ENVIRONMENT and ASPNETCORE_ENVIRONMENT to Production when you deploy it.

Reference

Tags

Tags

    Ads Blocker Image Powered by Code Help Pro

    Ads Blocker Detected!!!

    This site depends on revenue from ad impressions to survive. If you find this site valuable, please consider disabling your ad blocker.