private void FillListBox() { Userods.RefreshCache(); UserGroups.RefreshCache(); GroupPermissions.RefreshCache(); listUser.BeginUpdate(); listUser.Items.Clear(); if (PrefC.GetBool(PrefName.UserNameManualEntry)) { //Because _listUsers is used to verify the user name typed in, we need to include both non-hidden and CEMT users for offices that type in their credentials instead of picking. _listUsers = Userods.GetUsers(true); } else //This will be the most common way to fill the user list. Includes CEMT users. { _listUsers = Userods.GetUsers(true); } for (int i = 0; i < _listUsers.Count; i++) { listUser.Items.Add(_listUsers[i]); } listUser.SelectedIndex = 0; listUser.EndUpdate(); }