Wrox Programmer Forums
|
ASP.NET 1.1 As of 10/6/2005, this forum is locked as part of the reorganization described here: http://p2p.wrox.com/topic.asp?TOPIC_ID=35394. No posts have been deleted. Open ongoing discussions from the last week have been moved to either ASP.NET 1.0 and 1.1 Beginners http://p2p.wrox.com/asp-net-1-0-1-1-basics-60/ or ASP.NET 1.0 and 1.1 Professional. http://p2p.wrox.com/forum.asp?FORUM_ID=50. See my sticky post inside for more.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.1 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 16th, 2004, 10:57 AM
Authorized User
 
Join Date: Jul 2004
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default maintaining Session state

(Thanks, Vadivel)
To clear all the Session variables when a particular user's Session terminate, is it necessary to add code to the "protected void Session_End(Object sender, EventArgs e){}" method in Global.asax.cs?
Like "Session.RemoveAll();"? Thanks.


 
Old December 17th, 2004, 01:32 AM
Friend of Wrox
 
Join Date: Dec 2004
Posts: 307
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to Vadivel Send a message via Yahoo to Vadivel
Default

If you worrying about "Sign out" or "Log out" options on a site .. then on the click event of that button just add
1. Session.Abandon()
2. Session.RemoveAll()

and then you load a new page ... something like, Server.Transfer("HomePage.aspx"). Hope this helps!

Best Regards
Vadivel

MVP ASP/ASP.NET
http://vadivel.thinkingms.com





Similar Threads
Thread Thread Starter Forum Replies Last Post
maintaining session state in C# grs General .NET 0 January 13th, 2005 03:46 AM
Having trouble with Maintaining Session State kmattera Classic ASP Basics 0 December 7th, 2004 08:47 PM
Maintaining State in Tables MikeSchnell ASP.NET 1.0 and 1.1 Basics 1 March 25th, 2004 01:22 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.