25 February, 2013

Cannot find form to submit

I added an XForm to a page in EPiServer 7 using the built in XForms functionality.

When the user submitted the form they got the following error:

Cannot find form to submit (in EPiServer.XForms.WebControls.Submit.SubmitForm)

My stupid mistake was that I accidentally datda bound the xform property on page load...

I had a placeholder around it to control what to display when, and I data bound it without checking for post back... (I know, a newbie misstake ;-) )


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

            //FormPlaceHolder.DataBind();
            if(!IsPostBack) FormPlaceHolder.DataBind();


Stupid mistake, easy solution :-)

No comments:

Post a Comment