void OnDeleteAllUsers(object sender, EventArgs e) { DialogResult result = MessageBox.Show("Are you sure you want to delete all the users?", "Credentials Manager", MessageBoxButtons.OKCancel); if (result == DialogResult.OK) { IMembershipManager membershipManager = UserManagerProviderFactory.CreateMembershipManager(); // new AspNetSqlProviderService(ServiceAddress); membershipManager.DeleteAllUsers(ApplicationName, m_RelatedDataCheckBox.Checked); //Update the users page m_UsersListView.ClearItems(); RefreshUserStatus(); RefreshUsersPageButtonsAndMenuItems(); //Upade the roles page RefreshUsersToAssignListView(); RefreshUsersForRoleComboBox(); RefreshRolesForUserComboBox(); RefreshRolePageButtons(); } }