iControl.ConnectionInfo.saveToRegistry C# (CSharp) Method

saveToRegistry() public method

public saveToRegistry ( ) : void
return void
        public void saveToRegistry()
        {
            Microsoft.Win32.RegistryKey cu = Microsoft.Win32.Registry.CurrentUser;
            Microsoft.Win32.RegistryKey f5Key = cu.CreateSubKey(CONFIG_KEY);
            if (null != f5Key)
            {
                f5Key.SetValue("Hostname", m_hostname);
                f5Key.SetValue("Port", m_port);
                f5Key.SetValue("Username", m_username);
                if (null != m_proxy)
                {
                    f5Key.SetValue("UseProxy", true);
                    f5Key.SetValue("ProxyHost", m_proxy.Address.Host);
                    f5Key.SetValue("ProxyPort", m_proxy.Address.Port.ToString());
                    if (null != m_proxy.Credentials)
                    {
                        f5Key.SetValue("ProxyUser", ((System.Net.NetworkCredential)m_proxy.Credentials).UserName);
                    }
                }
            }
            f5Key.Close();
        }

Same methods

ConnectionInfo::saveToRegistry ( String m_hostname ) : void