Problem with ModalPopupExtender with DataList

Topics: Web Client Software Factory, User Forum
Oct 10, 2007 at 11:30 AM
I have a problem with binding my businessobject to my popuppanel (with an AjaxControlToolkit Accordion) using ModalPopupExtender.

The case:

I have a DataList (in a usercontrol, ListView.ascx) with LinkButtons, if you click on a LinkButton the popuppanel shows with the Accordion where the texboxes should be filled with data from the businessobject.

The problem:

This is not working. After I have fetched the right businessobject I'm not able to populate the popupPanel or more precisly the texboxses in the Accordion.

So....In my ListView.aspx page I have a the UserControl (ListView.ascx) that contains a DataList, when a LinkButton is clicked the UserControl raises an event.

In my ListView.aspx page I handle this event like this:

void ListView1_SelectedItemChanged(object sender, ListViewEventArgs e)
{
object obj = e.ItemID;
if (obj != null)
{
int objectID = Convert.ToInt32(obj);
businessObj = _presenter.GetForbindelse(objectID);
GUIReflection.BindObjectToControls(businessObj, Accordion1);
this.ModalPopupExtender1.Show();
}
}

I get the objectID and get the businessobject (businessObj) from server successfully. But when I call ModalPopupExtender.Show() it contains no businessobject data.

Guess this has something to do with when the Accordion-panes loads or something? Anyone experienced something like this?

NB! I'm using Web Client Software Factory and Ajax Control Toolkit.

LFC