コード例 #1
0
ファイル: NewJobDialog.xaml.cs プロジェクト: ExiaHan/z3test
        private void btnSelectCategories_Click(object sender, RoutedEventArgs e)
        {
            Mouse.OverrideCursor = System.Windows.Input.Cursors.Wait;

            string[] currentSelection = txtCategories.Text.Split(',');
            ChooseCategories dlg = new ChooseCategories(txtSharedDir.Text, currentSelection);
            dlg.Owner = this;
            if (dlg.ShowDialog() == true)
            {
                txtCategories.Text = "";

                foreach (string s in dlg.listBox.SelectedItems)
                {
                    if (txtCategories.Text.Length != 0) txtCategories.Text += ",";
                    txtCategories.Text += s;
                }
            }

            Mouse.OverrideCursor = null;
        }
コード例 #2
0
        private void btnSelectCategories_Click(object sender, RoutedEventArgs e)
        {
            Mouse.OverrideCursor = System.Windows.Input.Cursors.Wait;

            string[]         currentSelection = txtCategories.Text.Split(',');
            ChooseCategories dlg = new ChooseCategories(txtSharedDir.Text, currentSelection);

            dlg.Owner = this;
            if (dlg.ShowDialog() == true)
            {
                txtCategories.Text = "";

                foreach (string s in dlg.listBox.SelectedItems)
                {
                    if (txtCategories.Text.Length != 0)
                    {
                        txtCategories.Text += ",";
                    }
                    txtCategories.Text += s;
                }
            }

            Mouse.OverrideCursor = null;
        }