Authentication

When a web page requires authentication, EO.WebBrowser raises NeedCredentials event. If you do not handle this event, the default implementation displays a dialog asking users for a user name and a password.

You can handle this event to automatically supply user name or password, or replace the default dialog with your custom dialog. Inside your event handler, you should call Continue method on the event argument object to supply the user name and password. If you handle the event but does not call this method in your event handler, then the request will be canceled.

The following code demonstrates how to supply an user name and password directly without displaying any UI:

//Attach the event handler
webView.NeedCredentials += WebView_NeedCredentials;

private void WebView_NeedCredentials(object sender, NeedCredentialsEventArgs e)
{
    //Replace "username" and "password" with the actual user name and password
    e.Continue("username", "password");
}