hie... here i'm doing my cookie clear when i do logout... my cookie have to be deleted as well when i reopen my application it wont be open the Account page directly it must ask to login again.. so i'm using while loging out... i'm doing deleting my cookie.....
if ( Request.Cookies["MyCookie"] != null )
{
var c = new HttpCookie( "MyCookie" );
c.Expires = DateTime.Now.AddDays( -1 );
Response.Cookies.Add( c );
}
{
var c = new HttpCookie( "MyCookie" );
c.Expires = DateTime.Now.AddDays( -1 );
Response.Cookies.Add( c );
}
No comments:
Post a Comment