Hello ASPX expert !!
Here is my problem.
I have a datagrid binded to a dataview.
I edit the datagrid and change the value of my textBoxes from my datagrid.
When I click to update the data,
What I read is the old values (txtProduitVIPN o)
Any Idea??
thanks in advance !!
Esperanza !!
private void dgAdminCommande s_UpdateCommand (object source,
System.Web.UI.W ebControls.Data GridCommandEven tArgs e)
{
TextBox txtProduitVIPNo = (TextBox)e.Item .FindControl("t xtProduitVIPNo" );
TextBox txtProduitVIPNo m = (TextBox)e.Item .FindControl("t xtProduitVIPNom ");
this.updCoopCom mandes.Paramete rs["@OrderID"].Value =
dgCoopCommandes .DataKeys[e.Item.ItemInde x];
this.updCoopCom mandes.Paramete rs["@ProduitVI PNo"].Value =
txtProduitVIPNo .Text;
this.updCoopCom mandes.Paramete rs["@ProduitVIPNom "].Value =
txtProduitVIPNo m.Text;
this.updCoopCom mandes.Paramete rs["@TMPSTP_AD M"].Value = System.DateTime .Now;
this.sqlConn.Op en();
this.updCoopCom mandes.ExecuteN onQuery();
this.sqlConn.Cl ose();
}
Here is my problem.
I have a datagrid binded to a dataview.
I edit the datagrid and change the value of my textBoxes from my datagrid.
When I click to update the data,
What I read is the old values (txtProduitVIPN o)
Any Idea??
thanks in advance !!
Esperanza !!
private void dgAdminCommande s_UpdateCommand (object source,
System.Web.UI.W ebControls.Data GridCommandEven tArgs e)
{
TextBox txtProduitVIPNo = (TextBox)e.Item .FindControl("t xtProduitVIPNo" );
TextBox txtProduitVIPNo m = (TextBox)e.Item .FindControl("t xtProduitVIPNom ");
this.updCoopCom mandes.Paramete rs["@OrderID"].Value =
dgCoopCommandes .DataKeys[e.Item.ItemInde x];
this.updCoopCom mandes.Paramete rs["@ProduitVI PNo"].Value =
txtProduitVIPNo .Text;
this.updCoopCom mandes.Paramete rs["@ProduitVIPNom "].Value =
txtProduitVIPNo m.Text;
this.updCoopCom mandes.Paramete rs["@TMPSTP_AD M"].Value = System.DateTime .Now;
this.sqlConn.Op en();
this.updCoopCom mandes.ExecuteN onQuery();
this.sqlConn.Cl ose();
}
Comment