C#.net is having webbrowser control for creating applications useful for automatically navigating/crawling websites.
It will be required to delete these cookies in webbrowser control when using it for different set of user logins.
Below C# function will be useful for deleting the cookie for IE (Internet Explorer) browser. As webbrowser control will share the cookie with IE, this code can be used for deleting webbrowser control cookie.
I heard that cookie will be stored somewhere temporarily also, and this function won't delete it. But I am not sure about. If anyone know more details about this temporary cookie you can share it here.
private void deletecookie()
string theCookies = System.IO.Directory.GetFiles(Environment.GetFolderPath(Environment.SpecialFolder.Cookies));
foreach(string currentFile in theCookies)
catch (Exception ex)