Exemplo n.º 1
0
        //检测是否已注册
        private bool IsRegister()
        {
            CdKeyTools tools = new CdKeyTools();
            string     cdkey = tools.GetRegisterCdkey();

            if (!string.IsNullOrEmpty(cdkey) &&
                cdkey == tools.GetCdKey())
            {
                return(true);
            }
            return(false);
        }
Exemplo n.º 2
0
        private bool SoftRegister(string cdkey)
        {
            CdKeyTools tools = new CdKeyTools();
            string     mykey = tools.GetCdKey();

            if (cdkey == mykey)
            {
                //写注册表
                tools.WriteRegister(cdkey);
                return(true);
            }
            return(false);
        }