Exemple #1
0
 protected void bienmueble_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (this.bienmueble.SelectedValue.ToString() == "Seleccione")
     {
         this.txtTipoVehiculo.Text    = "";
         this.txtaniofabricacion.Text = "";
         this.txtpatente.Text         = "";
         this.txtmarca.Text           = "";
         this.txtchassis.Text         = "";
         this.txtEstado.Text          = "";
     }
     else
     {
         DataTable table = null;
         table = ConsultasEspecificas.MostrarDatosBienMueble(this.bienmueble.SelectedValue.ToString());
         if ((table.Rows.Count > 0) && (table != null))
         {
             this.txtTipoVehiculo.Text    = table.Rows[0]["tipovehiculo"].ToString();
             this.txtaniofabricacion.Text = table.Rows[0]["anio_fabricacion"].ToString();
             this.txtpatente.Text         = table.Rows[0]["patente"].ToString();
             this.txtmarca.Text           = table.Rows[0]["marca"].ToString();
             this.txtchassis.Text         = table.Rows[0]["n_chassis"].ToString();
             this.txtEstado.Text          = table.Rows[0]["estado"].ToString();
         }
     }
 }