private void Connect_Secure(string current_url)
{
try
{
using (LoginForm login = new LoginForm())
{
DialogResult res = login.ShowDialog();
authentication_needed = true;
if (res == System.Windows.Forms.DialogResult.OK)
{
loggedIn = false;
webBrowser1.Navigate(String.Format(@"http://{0}:{1}@{2}", login.getUsername(), login.getPassword(), current_url.Substring(7)));
}
else
{
loading.Visible = false;
exceptionRaised = true;
}
}
}
catch
{
if (isAutoUpdate)
FindNewIP();
else
DisplayPage(url);
return;
}
}