Can you give an example of what might be best suited to place in the Application_Start and Session_Start subroutines?

Submitted by: Administrator
To provide individual data for a user during a session, data can be stored with session scope. In the following sample, values for user preferences are initialized in the Session_Start event in the Global.asax file.Sub Session_Start() Session("BackColor") = "beige" ...End Sub'======================================================================In the following sample a file is read in Application_Start (defined in the Global.asax file) and the content is stored in a DataView object in the application state.Sub Application_Start() Dim ds As New DataSet() Dim fs As New FileStream(Server.MapPath("schemadata.xml"),FileMode.Open,FileAccess.Read) Dim reader As New StreamReader(fs) ds.ReadXml(reader) fs.Close() Dim view As New DataView (ds.Tables(0)) Application("Source") = viewEnd Sub
Submitted by: Administrator

Read Online ASP.NET 2.0 Job Interview Questions And Answers