public static void SetControlAccounts(List <AdminPanelControlAccount> cAccounts) { try { XMLayer xm = XMServer.CreateXMLayer(); string param = string.Empty; foreach (AdminPanelControlAccount ca in cAccounts) { param += '\"' + ca.Name + '\"' + '\t' + '\"' + AdminPanelUtils.EncryptPassword(ca.Password) + '\"' + "\r\n"; } xm.Login(); xm.SetCtrlAccounts(param); xm.Logout(); } catch (Exception error) { Log.WriteException(error); throw new WebMail.WebMailException(error); } }