/// <summary> /// In forms constructor the not necessarily labels and tetxboxes are hiding /// from the form. Then the combobox for ratings(CmbSelect) is filling /// from the rating(rating) table. /// </summary> public EditReservationForm() { InitializeComponent(); LblBusiness.Hide(); LblDate.Hide(); LblPerson.Hide(); LblUsername.Hide(); CmbBusiness.Hide(); CmbUsername.Hide(); BtnEdit.Hide(); TbxPerson.Hide(); DtpDate.Hide(); CmbSelect.DataSource = DCom.GetData("SELECT *, CONCAT(Username, ', ', Rating_Value) AS NAME FROM ratings"); CmbSelect.DisplayMember = "NAME"; CmbSelect.ValueMember = "ID"; }