Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
DataSet as DataSource for the GridView
Message
 
 
À
16/09/2008 11:10:26
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Versions des environnements
Environment:
C# 3.0
OS:
Windows XP
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01347730
Message ID:
01347944
Vues:
8
Hi Viv,

This code in FormView_ItemUpdated worked great. I now just need to list all the fields in the grid. I didn't add a check if the fields were actually changed.
// We now need to refresh the DataSet
            if (Session["dts"] != null)
            {
                DataSet ds = (DataSet)Session["dts"];
                DataRow[] PersonRow =
                    ds.Tables[0].Select("PersonID = '" + this.SelectedPersonID.ToString() + "'");
                if (PersonRow != null)
                {
                    PersonRow[0]["FirstName"] = (string)e.NewValues["FirstName"];
                    PersonRow[0]["LastName"] = (string)e.NewValues["LastName"];
                    this.ProfilesGrid.DataBind();
                }
            }
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform