PagingControl triggers XForms

Vote:
 

hi!

i'm using an EPiserver:Pagelist and a XForms:XFormcontrol on the same page in a CMS-site. when i click on one of the pagenumber in the pagingcontrol, it submits the xform instead of getting the next set of items in the pagelist. both the pagingcontrol and the xform uses webform_DoPostBackWithOptions. what am i missing here?

#24045
Sep 22, 2008 15:36
Vote:
 

The PagingControl will trigger validation of the xform - a workaround is to loop through the controls in pre_render and set CausesValidation="false".

protected override void OnPreRender(EventArgs e)
{
base.OnPreRender(e);

foreach (Control c in epiPageList.PagingControl.Controls)
{
if (c is LinkButton)
(c as LinkButton).CausesValidation = false;
}
}

 

 

#24079
Sep 23, 2008 15:30
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.