What is the difference between application object and
session object?

Answer Posted / sridevipc

A session is the time for which a particular user interacts
with a web application.

that data stored in session is not permanent and data
stored is usually only available to a specific user

Sessions serve as a way to transport and maintain user data
in web pages, such as forums, or e-commerce websites.

The Application object stores data that is shared accross
the application and not for a specific user. Internally the
values of both the Session and Application objects are
stored in a key/value pair (HashTable). All data stored in
Application in stored 'in process', meaning if you restart
your application all data in lost (I will show you how to
maintain all application data in another tutorial).

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is authorization in asp.net?

818


What is a ashx file?

788


What is the default timeout for a cookie?

804


What are the benefits of Razor View?

768


How do we sort the data from a dataset?

780


Mention the namespace that is used to include .net data provider for sql server in .net code?

732


Explain About WebService

917


8. Why do you want to work here?

1684


Explain about asp.net 2.0 themes?

750


If 200 is for all successful operation then why do we have 201 response codes?

743


Differentiate globalization and localization.

803


What is the sequence in which ASP.NET events are processed?

723


Hi this is the coding for adding data in to an xml table i want the coding for update and delete Try Dim emp_xml_doc As New XmlDocument If System.IO.File.Exists(Server.MapPath("emp.xml")) Then emp_xml_doc.Load(Server.MapPath("emp.xml")) Dim myrow_element As XmlElement myrow_element = emp_xml_doc.CreateElement("EmpDetails") Dim str As String str = "" & TxtEmpId.Text & "" & _ "" & TxtName.Text & "" & _ "" & TxtSalary.Text & "" myrow_element.InnerXml = str emp_xml_doc.DocumentElement.AppendChild(myrow_element) emp_xml_doc.Save(Server.MapPath("emp.xml")) Response.Write("Record Saved") Dim ds As New DataSet ds.ReadXml(Server.MapPath("emp.xml")) GridView1.DataSource = ds GridView1.DataBind() Else Response.Write("File does not exist.") End If Catch ex As Exception Response.Write(ex.ToString) End Try *********************** this is the xml file 100 xxx 2000 yyy dddd 77777 rrrr rrrr 6666 qaqa sini 50000 errrrrrrrr rrrrrrrrr 677777 rrr rrr 33

1957


Name the namespace which is used by ado.net?

744


If you are using components in your application, how can you handle exceptions raised in a component?

2331