public void TraerProducto(DataGridView DgvMostrar)
        {
            DgvMostrar.Rows.Clear();
            ProductoTableAdapter adapter = new ProductoTableAdapter();
            ProductoDataTable    mitabla = adapter.GetData();

            for (int i = 0; i < mitabla.Count; i++)
            {
                ProductoRow misRegistro = (ProductoRow)mitabla.Rows[i];
                DgvMostrar.Rows.Add(
                    null,
                    misRegistro.IdProducto,
                    misRegistro.Producto
                    );
            }
        }
Exemplo n.º 2
0
 public static DSFacturacion.ProductoDataTable GetProductos()
 {
     return(adapter.GetData());
 }