private void tbNamaPasien_Leave(object sender, EventArgs e) { if (tbNamaPasien.Text != "" && SqliteDataAccess.CheckIfPasienExist(tbNamaPasien.Text)) { MessageBox.Show("Nama Pasien sudah terdaftar", "Error"); tbNamaPasien.Text = ""; } }
private void tbNoRM_Leave(object sender, EventArgs e) { if (tbNoRM.Text != "" && SqliteDataAccess.CheckIfPasienExist(Convert.ToInt32(tbNoRM.Text))) { MessageBox.Show("No. RM sudah terdaftar", "Error"); tbNoRM.Text = ""; } }