Esempio n. 1
0
        private void FormHoteles_Load(object sender, EventArgs e)
        {
            //bindingSourceHoteles.DataSource = Bd.HotelesSelect();
            bindingSourceCiudades.DataSource = Bd.CiudadesSelect();

            ciudades c = Bd.CiudadesSelectPorId((int)comboBoxCiudades.SelectedValue);

            bindingSourceHoteles.DataSource = c.hoteles;
        }
Esempio n. 2
0
        private void buttonInsert_Click(object sender, EventArgs e)
        {
            string mensaje = Bd.CiudadInsert(int.Parse(textBoxIdentificador.Text), textBoxNombre.Text);

            if (mensaje != "")
            {
                MessageBox.Show(mensaje);
            }
            else
            {
                MessageBox.Show("Alta correcta");
            }
        }
Esempio n. 3
0
        private void comboBoxCiudades_SelectedIndexChanged(object sender, EventArgs e)
        {
            ciudades c = Bd.CiudadesSelectPorId((int)comboBoxCiudades.SelectedValue);

            bindingSourceHoteles.DataSource = c.hoteles;
        }