Example #1
0
        //# Agregar Registro de Cada Carro de Apoyo
        private void CargarGrilla()
        {
            dgv_Apoyos.Rows.Clear();
            string strID      = "";
            string strNombre  = "";
            string strTipo    = "";
            string strCia     = "";
            bool   hab        = false;
            string strIdCarro = "";

            foreach (DataRow cApoyo in carros.GetCarrosApoyo().Tables[0].Rows)
            {
                strID     = cApoyo["car_apoyo"].ToString();
                strNombre = cApoyo["nombre"].ToString();
                //strTipo = cApoyo["id_tipo_carro"].ToString();
                strTipo    = cApoyo["nom_apoyo"].ToString();
                strCia     = cApoyo["id_compania"].ToString();
                hab        = Convert.ToBoolean(cApoyo["habilitado"]);
                strIdCarro = cApoyo["id_carro"].ToString();

                dgv_Apoyos.Rows.Add(strID, strNombre, strTipo, strCia, hab, strIdCarro);
            }
        }