private void fillComponentsCombo() { comboBoxComponents.Items.Clear(); int addedComponentsCount = 0; string libPath = AsposeComponentsManager.getLibaryDownloadPath(); foreach (AsposeComponent component in AsposeComponents.list.Values) { if (Directory.Exists(Path.Combine(libPath, component.Name))) { comboBoxComponents.Items.Add(component.Name); addedComponentsCount++; } } if (!string.IsNullOrEmpty(GlobalData.SelectedComponent)) { comboBoxComponents.SelectedItem = GlobalData.SelectedComponent; GlobalData.SelectedComponent = string.Empty; } if (addedComponentsCount == 0) { ComponentWizardPage components = new ComponentWizardPage(); components.FormClosed += new FormClosedEventHandler(components_FormClosed); components.ShowDialog(); if (!GlobalData.isComponentFormAborted) { fillComponentsCombo(); } } }
private void fillComponentsCombo() { comboBoxComponents.Items.Clear(); int addedComponentsCount = 0; string libPath = AsposeComponentsManager.getLibaryDownloadPath(); foreach (AsposeComponent component in AsposeComponents.list.Values) { if (Directory.Exists(Path.Combine(libPath, component.Name))) { comboBoxComponents.Items.Add(component.Name); addedComponentsCount++; } } if (!string.IsNullOrEmpty(GlobalData.SelectedComponent)) { comboBoxComponents.SelectedItem = GlobalData.SelectedComponent; GlobalData.SelectedComponent = string.Empty; } if (addedComponentsCount == 0) { ComponentWizardPage components = new ComponentWizardPage(); components.FormClosed += new FormClosedEventHandler(components_FormClosed); components.ShowDialog(); if (!GlobalData.isComponentFormAborted) fillComponentsCombo(); } }
private void GetComponentsButton_Click(object sender, EventArgs e) { GlobalData.isAutoOpened = false; ComponentWizardPage wizardpage = new ComponentWizardPage(); wizardpage.ShowDialog(); fillComponentsCombo(); }