コード例 #1
0
        public bool CheckAuthentication()
        {
            string keyFile = CommonFunc.GetKeyfilePath();

            if (!System.IO.File.Exists(keyFile))
            {
                return(false);
            }
            return(true);
        }
コード例 #2
0
        private bool CheckKeyFileAvailable()
        {
            string keyFile = CommonFunc.GetKeyfilePath();

            if (!File.Exists(keyFile))
            {
                if (!CheckAuthentication())
                {
                    MessageBox.Show("Authentication failed!");
                    return(false);
                }
            }

            return(true);
        }