コード例 #1
0
        private void buttonOptions_Click(object sender, EventArgs e)
        {
            try
            {
                FormOptions dialog = new FormOptions(_rootDirectory);
                if (DialogResult.OK == dialog.ShowDialog(this))
                {
                    _rootDirectory = dialog.RootDirectory;


                    foreach (ListViewItem item in listViewExamples.Items)
                    {
                        IExample example = item.Tag as IExample;
                        item.Text = example.Caption;
                        item.SubItems[1].Text = example.Description;
                    }

                    Translator.TranslateControls(this, "FormBase.txt", FormOptions.LCID);
                }
            }
            catch(Exception exception)
            {
                FormError.Show(this, exception);  
            }
        }
コード例 #2
0
ファイル: FormBase.cs プロジェクト: netintellect/NetOffice
        private void buttonOptions_Click(object sender, EventArgs e)
        {
            try
            {
                FormOptions dialog = new FormOptions(_rootDirectory);
                if (DialogResult.OK == dialog.ShowDialog(this))
                {
                    _rootDirectory = dialog.RootDirectory;


                    foreach (ListViewItem item in listViewExamples.Items)
                    {
                        IExample example = item.Tag as IExample;
                        item.Text = example.Caption;
                        item.SubItems[1].Text = example.Description;
                    }

                    Translator.TranslateControls(this, "FormBase.txt", FormOptions.LCID);
                }
            }
            catch(Exception exception)
            {
                FormError.Show(this, exception);  
            }
        }