public static void GetWUUsers() { CurrentAccounts.Clear(); List <WUAccount> results = new List <WUAccount>(); int count = GetTotalWUAccounts(); if (count == 0) { WUAccount account = new WUAccount(); account.UserName = "******"; account.AccountType = "Microsoft"; results.Add(account); } else { for (int i = 0; i < count; i++) { WUAccount account = new WUAccount(); account.UserName = GetWUAccountUserName(i); account.AccountType = "Microsoft"; results.Add(account); } } CurrentAccounts = results; }
public static void GetWUUsers() { CurrentAccounts.Clear(); List <WUAccount> results = new List <WUAccount>(); int count = GetTotalWUAccounts(); WUAccount default_account = new WUAccount(); default_account.UserName = "******"; default_account.AccountType = "(No Authentication)"; results.Add(default_account); for (int i = 0; i < count; i++) { WUAccount account = new WUAccount(); account.UserName = GetWUAccountUserName(i); account.AccountType = GetWUProviderName(i); results.Add(account); } CurrentAccounts = results; }