/// <summary> /// 删除用户数据 /// </summary> /// <param name="infos"></param> /// <returns></returns> public bool DeleteDatabaseToUser(params UserInfo[] infos) { UserInfoDll user = new UserInfoDll(); int cout = user.Delete(infos.ToList()); if (cout == infos.Length) { return(true); } else { return(false); } }
private static void DeleUserData() { string dllPath = AppDomain.CurrentDomain.SetupInformation.ApplicationBase; string userPath = dllPath.Replace("application\\", "Cofigure\\SerializeUser.dat"); if (File.Exists(userPath)) { try { File.Delete(userPath); } catch { } } UserInfoDll user = new UserInfoDll(); user.Delete(user.GetList()); }