public void SetSelectedListSetting(string webURL, string rootFolderPath, string listName) { Settings = EUSettingsManager.GetInstance().Settings; if (Settings == null) { Settings = new EUSettings(); } EUListSetting listSetting = null; foreach (EUListSetting tempListSetting in Settings.ListSettings) { if (tempListSetting.RootFolderPath == rootFolderPath) { listSetting = tempListSetting; } } if (listSetting == null) { listSetting = new EUListSetting(); listSetting.RootFolderPath = rootFolderPath; listSetting.WebURL = webURL; listSetting.ListName = listName; Settings.ListSettings.Add(listSetting); } EmailMappingControl.BindEmailMapping(listSetting); SelectedListSetting = listSetting; }
private void SettingsForm_Load(object sender, EventArgs e) { if (Settings == null) { Settings = EUSettingsManager.GetInstance().Settings; } if (Settings == null) { Settings = new EUSettings(); return; } if (Settings.SaveAsWord == true) { WordPlusAttachmentsRadioButton.Checked = true; } else { EmailRadioButton.Checked = true; } UploadAutomaticallyCheckBox.Checked = Settings.UploadAutomatically; DetailedLogCheckBox.Checked = Settings.DetailedLogMode; LoadListSettings(); LoadSites(); if (SelectedListSetting == null) { EmailMappingControl.BindEmailMapping(Settings.DefaultListSetting); } else { EmailMappingControl.BindEmailMapping(SelectedListSetting); EmailMappingSettingsComboBox.SelectedItem = SelectedListSetting; SettingsTabControl.SelectedTab = ListSettingTabPage; } }
private void EmailMappingSettingsComboBox_SelectedIndexChanged(object sender, EventArgs e) { if (EmailMappingSettingsComboBox.SelectedItem != null) { EUListSetting listSetting = (EUListSetting)EmailMappingSettingsComboBox.SelectedItem; EmailMappingControl.BindEmailMapping(listSetting); } }