Beispiel #1
0
        //Add a new Prescription
        private void Prescription_Click(object sender, EventArgs e)
        {
            if (dataViewPatient.SelectedRows.Count > 0)
            {
                int patientID = Convert.ToInt32(dataViewPatient.SelectedRows[0].Cells[0].Value);
                //Current user
                int staffID = 10000000;

                FormPrescriptionDetail formPD = new FormPrescriptionDetail(staffID, patientID);
                formPD.ShowDialog();
            }
        }
Beispiel #2
0
        private void buttonPrescpitionEdit_Click(object sender, EventArgs e)
        {
            if (dataViewPrescription.SelectedRows.Count > 0)
            {
                int prescriptionID            = Convert.ToInt32(dataViewPrescription.SelectedRows[0].Cells[0].Value);
                FormPrescriptionDetail formPD = new FormPrescriptionDetail(Prescription.GetPrescription(prescriptionID), "edit");
                formPD.ShowDialog();

                refreshDataViewPrescription();
                refreshDataViewPrescriptionDetail();
            }
        }
        private void dataViewPrescription_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (dataViewPrescription.SelectedRows.Count > 0)
            {
                int prescriptionID = Convert.ToInt32(dataViewPrescription.SelectedRows[0].Cells[0].Value);
                FormPrescriptionDetail formPD = new FormPrescriptionDetail(Prescription.GetPrescription(prescriptionID), "edit");
                formPD.ShowDialog();

                refreshDataViewPrescription();
                refreshDataViewPrescriptionDetail();
            }
        }
Beispiel #4
0
        //Add a new Prescription
        private void Prescription_Click(object sender, EventArgs e)
        {
            if (dataViewPatient.SelectedRows.Count > 0)
            {
                int patientID = Convert.ToInt32(dataViewPatient.SelectedRows[0].Cells[0].Value);
                //Current user
                int staffID = 10000000;

                FormPrescriptionDetail formPD = new FormPrescriptionDetail(staffID, patientID);
                formPD.ShowDialog();
            }

        }