PC Review


Reply
Thread Tools Rate Thread

Re: Application_End event does't start

 
 
Marina
Guest
Posts: n/a
 
      3rd Feb 2004
Then I guess your application hasn't ended yet.

"Junior_BR" <(E-Mail Removed)> wrote in message
news:54D2B81B-0FA2-4D78-90EF-(E-Mail Removed)...
> I put a function to be called in the Application_End event on my

Global.asax file, but it does't fires in any way... I can undertand what's
happen. I put a breakpoint inside the event to view when they´re fired, but
it doesn't fire... Can anyone help me, please ???


 
Reply With Quote
 
 
 
 
=?Utf-8?B?SnVuaW9yX0JS?=
Guest
Posts: n/a
 
      4th Feb 2004
I have closed the browser and the Event doesn't fire... I have change to another page, and the event doesn't fires too... I think the application it's realy ended, and the event realy don't works...
 
Reply With Quote
 
Alvin Bruney [MVP]
Guest
Posts: n/a
 
      4th Feb 2004
tehehe, i think its a bug :-). It's not actually, i'm having fun here
because a few moons ago i was convinced of that same thing until someone
taught me. I'm passing on what i've learned if you promise to do the same
when it is your turn.

what you have done so far doesn't guarantee that the end event will be
called. I wager that even if you shut down visual studio and bring it back
up, the application_end still won't fire. That's by design to mimic the
behavior of a production environment.

Here is how to trigger it. Put a break point in the application_end event
and run the application. Leave visual studio running minimized. Use notepad
to open the webconfig file, make an immaterial change to the web config file
and push save. Behold as the culprit is caught and exposed.

Here is the explanation: Your webpages run inside of an application object.
Do not confuse your web page with the application object. There really is
only limited dependency on the two. The webpage you see on screen in the
browser may initialize the application object if the application object
isn't already started because an application object is required. When you
close the browser, the application object is still running so the end event
won't fire. A few things can kill the application object causing its end
event to be fired. A dirty web config file (which we tried), a dirty global
asax file, a dirty assembly, iis resets. You didn't do any of those so the
end event wasn't being triggered.

--
Regards,
Alvin Bruney [ASP.NET MVP]
Got tidbits? Get it here...
http://tinyurl.com/3he3b
"Junior_BR" <(E-Mail Removed)> wrote in message
news:5039057A-C6DD-4296-8976-(E-Mail Removed)...
> I have closed the browser and the Event doesn't fire... I have change to

another page, and the event doesn't fires too... I think the application
it's realy ended, and the event realy don't works...


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Application_End event handler not getting called on developmentserver Tenacious Microsoft ASP .NET 5 11th Jan 2008 05:48 PM
Application_End =?Utf-8?B?c2Vhbl9tY2Fk?= Microsoft ASP .NET 4 3rd Apr 2007 02:12 AM
When is Application_End event called? =?Utf-8?B?c3VzaGk=?= Microsoft C# .NET 0 14th Jun 2005 04:18 PM
Re: ASP.NET Application_End Event Curt_C [MVP] Microsoft ASP .NET 2 15th Sep 2004 08:15 PM
Re: ASP.NET Application_End Event Steve C. Orr [MVP, MCSD] Microsoft ASP .NET 0 15th Sep 2004 08:02 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 11:46 PM.