Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error - re-binding a GridView
Message
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Divers
Thread ID:
01309102
Message ID:
01311813
Vues:
15
Kevin,

What happens is I have a lstRemainingLots_SelectedIndexChanged event where I call GetLotLineItems to repopulate the EntityList that the gvLots is bound to. As soon as I call the BO method that repopulates the EntityList, that's when the row_DataBound fires for the grid and I get the RowNotInTable error message.
protected void lstRemainingLots_SelectedIndexChanged(object sender, EventArgs e)
    {
        GetLotLineItems();
    }

private void GetLotLineItems()
{
if (!this.chkShowInactive.Checked)
{
//When LotLineItems.EntityList is repopulated
//gvLots_RowDataBound fires and RowNotInTable exception occurs
            LotLineItems.EntityList = LotLineItems.GetLotsByLidActive(Convert.ToInt32(lstRemainingLots.SelectedValue));
}
else
            LotLineItems.EntityList = LotLineItems.GetLotsByLid(Convert.ToInt32(lstRemainingLots.SelectedValue));

        Session["dsLots"] = LotLineItems.DataSet;
        this.BindControl(gvLots);
}
>E.R.,
>
>OK, and which specific line in this handler method is causing the error? The line number is displayed in the stack trace, but I don't know which line it is in the code you sent.
>
>Best Regards,
Regards,

E.R. Gilmore
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform