I am trying to emulate a web browser to execute JavaScript code and then parse the DOM. The System.Windows.Forms.WebBrowser object does not give me the functionality I need. This allowed me to set headers, but you cannot set proxies or clear cookies. Well, you can, but it's not perfect and mess with IE settings.
I have so far expanded the WebBrowser control by creating my own window functions, but this is really one hack on top of the other. I can communicate with the proxy server, as well as clear cookies, etc., but this control has its problems, which I talked about.
I found something called WebKit.NET ( http://webkitdotnet.sourceforge.net/ ), but I do not see support for setting a proxy or manipulating cookies.
Can anyone recommend a C ++ / library. NET / whatever for this:
Basically tell me what I need to do to get an interface similar to this in .NET:
string WebBrowserEmu::FetchBrowserParsedHtml(Uri url,
WebProxy p,
int timeoutSeconds,
byte[] headers,
byte[] postdata);
void WebBrowserEmu::ClearCookies();
I am not responsible for my actions.
source
share