public DataSet GetAll(string empresaid, tb_ta_tela_fallas BE)
 {
     using (SqlConnection cnx = new SqlConnection(conex.empConexion(empresaid)))
     {
         using (SqlCommand cmd = new SqlCommand("gspTbTaTelaFallas_SEARCH", cnx))
         {
             DataSet ds = new DataSet();
             {
                 cmd.CommandType = CommandType.StoredProcedure;
                 cmd.Parameters.Add("@fallaid", SqlDbType.Char, 2).Value = BE.fallaid;
                 cmd.Parameters.Add("@fallaname", SqlDbType.VarChar, 20).Value = BE.fallaname;
             }
             try
             {
                 cnx.Open();
                 using (SqlDataAdapter da = new SqlDataAdapter(cmd))
                 {
                     da.Fill(ds);
                 }
                 return ds;
             }
             catch (Exception ex)
             {
                 throw new Exception(ex.Message);
             }
         }
     }
 }
 public bool Delete(string empresaid, tb_ta_tela_fallas BE)
 {
     using (SqlConnection cnx = new SqlConnection(conex.empConexion(empresaid)))
     {
         using (SqlCommand cmd = new SqlCommand("gspTbTaTelaFallas_DELETE", cnx))
         {
             {
                 cmd.CommandType = CommandType.StoredProcedure;
                 cmd.Parameters.Add("@fallaid", SqlDbType.Char, 2).Value = BE.fallaid;
             }
             try
             {
                 cnx.Open();
                 if (cmd.ExecuteNonQuery() > 0)
                 {
                     return true;
                 }
                 else
                 {
                     return false;
                 }
             }
             catch (Exception ex)
             {
                 throw new Exception(ex.Message);
             }
         }
     }
 }
 public bool Update(string empresaid, tb_ta_tela_fallas BE)
 {
     return tablaDA.Update(empresaid, BE);
 }
 public bool Insert(string empresaid, tb_ta_tela_fallas BE)
 {
     return tablaDA.Insert(empresaid, BE);
 }
 public DataSet GetAll(string empresaid, tb_ta_tela_fallas BE)
 {
     return tablaDA.GetAll(empresaid, BE);
 }
 private void data_cbo_tipofallasid()
 {
     var BL = new tb_ta_tela_fallasBL();
     var BE = new tb_ta_tela_fallas();
     try
     {
         tipofallasid.DataSource = BL.GetAll(EmpresaID, BE).Tables[0];
         tipofallasid.ValueMember = "fallaid";
         tipofallasid.DisplayMember = "fallaname";
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }