Пример #1
0
        private void Form_Closed(object sender, EventArgs e)
        {
            Button n;

            if (inForm != null)
            {
                n = generateButton(inForm.Company.Text,
                                   inForm.Position.Text,
                                   inForm.Date_of_App.Text,
                                   inForm.Requisition_ID.Text,
                                   inForm.Addition_Info.Text);
                itemList.Add(n);
                placeIteminGrid(n);
                inForm = null;
            }
            else if (posForm != null)
            {
                n = generateButton(inForm.Company.Text,
                                   inForm.Position.Text,
                                   inForm.Date_of_App.Text,
                                   inForm.Requisition_ID.Text,
                                   inForm.Addition_Info.Text);
                itemList.Add(n);
                placeIteminGrid(n);
                posForm = null;
            }
        }
Пример #2
0
        private void showPosition(object sender, RoutedEventArgs e)
        {
            Button btn = sender as Button;

            String[] names = btn.Tag.ToString().Split(',');
            posForm = new PositionForm(names[0], names[1], names[2], names[3], names[4], SQLMan);
            posForm.Show();
            posForm.Closed += Form_Closed;
            e.Handled       = true;
        }