Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error - re-binding a GridView
Message
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Miscellaneous
Thread ID:
01309102
Message ID:
01311813
Views:
14
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
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform