private void dataGridView3_CellClick(object sender, DataGridViewCellEventArgs e) { SetButtonsActive2(); try { bookingS = ElementsSettings.SetDataFromLivingOrBookingDGVToTextBoxes(dataGridView3, e); idOfChosenRow3 = Convert.ToInt32(RequestsSQLT.SelectNthIdFromCustomerWherePassportDataDefinedToString(conn, Convert.ToInt32(bookingS[0]), Convert.ToInt32(bookingS[1]))); textBox17.Text = bookingS[5]; textBox16.Text = bookingS[6]; if (bookingS[7] != "") { idOfChosenRowBooking = Convert.ToInt32(bookingS[8]); } } catch { } }
private void dataGridView2_CellClick(object sender, DataGridViewCellEventArgs e) { SetButtonsActive1(); try { string[] s = ElementsSettings.SetDataFromLivingOrBookingDGVToTextBoxes(dataGridView2, e); idOfChosenRow2 = Convert.ToInt32(RequestsSQLT.SelectNthIdFromCustomerWherePassportDataDefinedToString(conn, Convert.ToInt32(s[0]), Convert.ToInt32(s[1]))); textBox12.Text = s[5]; textBox11.Text = s[6]; if (s[7] != "") { idOfChosenRowAS = Convert.ToInt32(s[7]); } if (s[8] != "") { idOfChosenRowLiving = Convert.ToInt32(s[8]); } } catch { } }