public bool CheckAuthentication() { string keyFile = CommonFunc.GetKeyfilePath(); if (!System.IO.File.Exists(keyFile)) { return(false); } return(true); }
private bool CheckKeyFileAvailable() { string keyFile = CommonFunc.GetKeyfilePath(); if (!File.Exists(keyFile)) { if (!CheckAuthentication()) { MessageBox.Show("Authentication failed!"); return(false); } } return(true); }