Exemplo n.º 1
0
        private void toolStripBtnWizyta_Click(object sender, EventArgs e)
        {
            bool IsOpen = false;

            foreach (Form f in Application.OpenForms)
            {
                if (f.Text == "Wizyta")
                {
                    IsOpen = true;
                    f.Focus();
                    break;
                }
            }
            if (IsOpen == false)
            {
                if (dataGridViewWizyta.RowCount != 0)
                {
                    this.Visible = false;
                    int row = dataGridViewWizyta.CurrentCell.RowIndex;
                    this.idwizyta = dataGridViewWizyta.Rows[row].Cells[4].Value.ToString();
                    Wizyta f2 = new Wizyta(this.idwizyta, false);
                    f2.ShowDialog();
                    this.Visible = true;
                    Update_Godziny();
                }
                else
                {
                    MessageBox.Show("Musisz wybrać wizyte!");
                }
            }
        }
Exemplo n.º 2
0
 public Zwolnienie(Wizyta parent)
 {
     InitializeComponent();
     this.MaximumSize  = this.Size;
     this.MinimumSize  = this.Size;
     this.rodzicWizyta = parent;
     //database.Conect() = "datasource=" + mysettings.Default.datasource + ";database=" + mysettings.Default.database + ";port=" + mysettings.Default.port + ";username="******";password="******";charset=utf8";
     Set_IDs();
     Update_danePacjent();
     Update_adresPacjent();
     Update_danePracownik();
     Update_comboBoxes();
 }
Exemplo n.º 3
0
 public SzukajProcedury(Wizyta parent, int buttonReceive)
 {
     InitializeComponent();
     this.MaximumSize  = this.Size;
     this.MinimumSize  = this.Size;
     this.rodzicWizyta = parent;
     this.button       = buttonReceive;
     //database.Conect() = "datasource=" + mysettings.Default.datasource + ";database=" + mysettings.Default.database + ";port=" + mysettings.Default.port + ";username="******";password="******";charset=utf8";
     if (this.button.Equals(1))
     {
         Update_Procedury();
         dataGridViewChoroba.Visible = false;
     }
     else if (this.button.Equals(2))
     {
         Update_Choroba();
         dataGridViewProcedury.Visible = false;
     }
 }
Exemplo n.º 4
0
 public Zwolnienie(string idzwolnieniaReceive, Wizyta parent)
 {
     InitializeComponent();
     this.MaximumSize = this.Size;
     this.MinimumSize = this.Size;
     //database.Conect() = "datasource=" + mysettings.Default.datasource + ";database=" + mysettings.Default.database + ";port=" + mysettings.Default.port + ";username="******";password="******";charset=utf8";
     this.idzwolnienia             = idzwolnieniaReceive;
     this.rodzicWizyta             = parent;
     this.Text                     = "Zwolnienie";
     buttonZapisz.Visible          = false;
     comboBoxUbezpieczonyW.Enabled = false;
     dateTimePickerOd.Enabled      = false;
     dateTimePickerDo.Enabled      = false;
     textBoxSzpital.Enabled        = false;
     comboBoxKody.Enabled          = false;
     comboBoxWskazania.Enabled     = false;
     Set_IDs();
     Update_danePacjent();
     Update_adresPacjent();
     Update_danePracownik();
     Update_daneNiezdolnosci();
 }