clear browser session and cookies using c#

1.8k views Asked by At

Hi I've created a new browser object by using

InternetExplorer myie = new SHDocVw.InternetExplorer(); and I'm trying to navigate to one page some thing like

myie.Navigate("https://myfirstsite.com/login.aspx", ref Empty, ref Empty, ref Empty, ref Empty);

Now I want to clear sessons and cookies for this myie object. How can I clear it?

Any idea?

1

There are 1 answers

0
Tedd Hansen On

You need to use wininet.dll to do this. Look at http://pastebin.com/E4V2XGbW for some samples.