Esempio n. 1
0
        private void toolStripComboBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            LetterType letterType = ((ApplicationState)ServiceProvider.GetService(typeof(ApplicationState))).SelectedLetterType;

            if (toolStripComboBox1.SelectedIndex >= 0 && null != _comboLettersTypes[toolStripComboBox1.SelectedIndex])
            {
                letterType.Id           = _comboLettersTypes[toolStripComboBox1.SelectedIndex].Id;
                letterType.Name         = _comboLettersTypes[toolStripComboBox1.SelectedIndex].Name;
                letterType.TypeClientUI = _comboLettersTypes[toolStripComboBox1.SelectedIndex].TypeClientUI;

                using (var makeLetterForm = new Forms.MakeLetterForm(ServiceProvider))
                {
                    makeLetterForm.ShowDialog();
                }
                InitializeMainWorkerForm();
            }
        }
Esempio n. 2
0
        private void InitializeMakeLetterForm(int SelectedTypeLetterIndex)
        {
            LetterType letterType = ((ApplicationState)ServiceProvider.GetService(typeof(ApplicationState))).SelectedLetterType;

            if (SelectedTypeLetterIndex >= 0 && null != _letterTypes[SelectedTypeLetterIndex])
            {
                letterType.Id           = _letterTypes[SelectedTypeLetterIndex].Id;
                letterType.Name         = _letterTypes[SelectedTypeLetterIndex].Name;
                letterType.TypeClientUI = _letterTypes[SelectedTypeLetterIndex].TypeClientUI;

                using (var makeLetterForm = new Forms.MakeLetterForm(ServiceProvider))
                {
                    if (makeLetterForm.ShowDialog() == DialogResult.OK)
                    {
                    }
                }
                InitializeMainWorkerForm();
            }
        }