GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  Microsoft  >  DotNet
Go To First  |  Previous Question  |  Next Question 
 DotNet  |  Question 61 of 165    Print  
Can you give an example of what might be best suited to place in the application_Start and Session_Start subroutines?

  
Total Answers and Comments: 3 Last Update: June 05, 2007   
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
January 13, 2006 07:08:34   
samiksc Member Since: October 2005   Contribution: 233    

RE: Can you give an example of what might be best suit...

Application_Start event should be used for initializing application-wide used variables and objects. For example if you want to find out number of connected users at any time you may initialize a variable user_count to 1 in Application_Start

Session_Start should be used to initialize session specific variables for example user name (to be shown on each page after the user loggs in) and other user preferences.


 
Is this answer useful? Yes | No
April 30, 2007 02:06:59   
deeptilove12002 Member Since: December 2006   Contribution: 1    

RE: Can you give an example of what might be best suit...

Application_Start:----generally placed in global.asax page...

As the first user visits the start page of a Web application this event is occurred...
this event is used to initialize the objects and data tht a user want to make available to all current sessions of the visited web applications..



Session_Start:----generally placed in global.asax page...

For each user visiting the web application it creartes a new instances of session variables used by the visitor.......


 
Is this answer useful? Yes | No
June 05, 2007 02:53:18   
Amar        

RE: Can you give an example of what might be best suit...
The best location to write such type of methods is Global.ascx
 
Is this answer useful? Yes | No


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2010 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape