I would like to point out some of the similarities/differences bewteen both Session and Profile objects:
Profile:
1- Profile object is scoped to a particular user:
Each user of a web application automatically has his own profile.
2- Profile object is persistant:
When you modify the stat os the profile object, the modifications are saved between visits to the website
3- Profile object uses the provider model to store information:
By default, the contents of a user profile are automatically saved to a Microsoft SQL Server Express database
located in App_Data of your web application.
4- Profile object is strongly typed:
Using strongly typed properties has several advantages. For example, you get full Microsoft IntelliSense when
using the Profile object in VS.NET 2005 or Visual Web Developer
Session:
1- Session object is scoped to a particular user:
Each user of a web application automatically has his own Session state.
2- Session object is non-persistant:
When you add an item to the Session object, the items disappear after you leave the Web site.
3- Session object uses three different ways to be stored:
3.1: In Process - default
3.2: State Server (Out of Process)
3.3: SQL Server
4- Session object is not strongly typed:
Sessopn object is simply a collection of items.
No comments:
Post a Comment