Expert question - Cancel Application_Start

A

AW

Hi all,

In my Application_Start, I'm initializing the application. ASP.Net calls my
Application_Start on the first request, not on the following ones.

However, if something goes wrong in my Application_Start I want to be able
to tell ASP.Net that the application wasn't started correctly so that it
calls my Application_Start on the next request.

Is this possible?

Thanks,
Arnaud
 
S

S. Justin Gengo

Arnaud,

Use a Try/Catch routine in application start to run the code of your choice
if an exception occurrs during application startup.

Try
'---Application startup code
Catch ex As Exception
'---Code to execute if application startup fails
End Try

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,906
Latest member
SkinfixSkintag

Latest Threads

Top