public FormBookingMake() { InitializeComponent(); Dictionary <string, TextBox> textBoxs = new Dictionary <string, TextBox>(); Dictionary <string, ComboBox> comboBoxs = new Dictionary <string, ComboBox>(); Dictionary <string, DateTimePicker> dateTimePickers = new Dictionary <string, DateTimePicker>(); comboBoxs.Add("Hotel", cbHotel); comboBoxs.Add("RoomType", cbRoomType); comboBoxs.Add("Room", cbRoom); dateTimePickers.Add("StartDate", dTPStart); dateTimePickers.Add("EndDate", dTPEnd); controller = new ControllerBooking(textBoxs, comboBoxs, dateTimePickers, labelTotal); }
public FormBookingClient() { InitializeComponent(); Dictionary <string, TextBox> textBoxs = new Dictionary <string, TextBox>(); Dictionary <string, ComboBox> comboBoxs = new Dictionary <string, ComboBox>(); Dictionary <string, DateTimePicker> dateTimePickers = new Dictionary <string, DateTimePicker>(); textBoxs.Add("Client", tbClient); comboBoxs.Add("Client", cbClient); comboBoxs.Add("Hotel", cbHotel); comboBoxs.Add("RoomType", cbRoomType); comboBoxs.Add("Room", cbRoom); dateTimePickers.Add("StartDate", dTPStart); dateTimePickers.Add("EndDate", dTPEnd); controller = new ControllerBooking(dgv, bnBooking, textBoxs, comboBoxs, dateTimePickers); controller.FillColumns(); }