7

I want to handle application shutdown gracefully when stopping debugging or stopping the IIS Express web site, but I cannot seem to get Application_End to run.

2 Answers 2

13

If you're debugging using IIS Express, the Application_End function will execute if you right-click on the IIS Express icon on the tray, select the proper site from the context menu and stop it. This will end your debugging session in a way that does execute the Application_End method.

1

Try to make a change in web.config and save.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.