コード例 #1
0
        public static void Reload()
        {
            RegistryKey server = RegistryUtil.HKLM.OpenSubKey("SOFTWARE\\Perspective Software\\Blue Iris\\server");

            if (server == null)
            {
                return;
            }
            enabled = RegistryUtil.GetStringValue(server, "enable") == "1";
            if (enabled)
            {
                try
                {
                    lanIp         = RegistryUtil.GetStringValue(server, "lanip");
                    bindLanIpOnly = RegistryUtil.GetStringValue(server, "bind") == "1";
                    port          = RegistryUtil.GetIntValue(server, "port", 80);
                    authenticate  = (AuthenticationMode)RegistryUtil.GetIntValue(server, "authenticate", 0);
                    secureonly    = RegistryUtil.GetStringValue(server, "secureonly") == "1";
                }
                catch
                {
                    enabled = false;
                }
            }
        }