adspace


how can we delete cookies by coding part . so pls help me

Answer Posted / Nitin Tenguriya

To delete cookies programmatically, you can use the C# HttpCookie class. Here is an example of how to delete a cookie named 'myCookie':n```csharpnHttpCookie myCookie = Request.Cookies["myCookie"];nif (myCookie != null) {n myCookie.Expires = DateTime.UtcNow.AddDays(-1);n Response.Cookies.Add(myCookie);n}n```

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

sir,please send me the NIC exam questions

2079


i want question papers of ASP

2097


who is the best Trainer for ASP.NET MVC in Hyderabad?

1577