Session Abandon Session Abandon

Session.Abandon() cancels current session. Let’s see how to call abandon method of Session.

Example Aspx page code.

<asp:Button ID="Button1" runat="server" Text="Button" OnClick="Button1_Click" />

Code behind

public partial class _Default : System.Web.UI.Page
  protected void Page_Load(object sender, EventArgs e)
  protected void Button1_Click(object sender, EventArgs e)


How are you using session variables in with Session TimeoutIRequiresSessionState and sessionSessions In Interview Questions for 2 years or 3 years experianceSession application viewstateSession Loss In WebgardenWhat is web garden in to implement Captcha in Asp.netasp net image upload


My name is Satalaj, but people call me Sat. Here is my homepage: . I live in Pune, PN and work as a Software Engineer. I'm former MVP in year 2010.
Disclaimer: Views or opinion expressed here are my personal research and it has nothing to do with my employer. You are free to use the code, ideas/hints in your projects. However, you should not copy and paste my original content to other web sites. Feel free to copy or extend the code.
If you want to fight with me, this website is not for you.

I'm Satalaj.