Two XForm related questions

Vote:
 
Hello, I have two questions related to XForm feature, so if anyone can help, please: 1. XFormStatistics - what could be the cause of this? Error 4 Element 'XFormStatistics' is not a known element. This can occur if there is a compilation error in the Web site. F:\1.0 Projects\SVD\SVN\trunk\src\Customer\Units\XForm.ascx 13 14 SvenskaDagbladet 2. AfterSubmitPostedData event doesn't get triggered if "Page shown after the form has been sent" property is set to same page as where form is. Meaning, if I want the form to be redirected to itself, this event get's attached by FormControl.AfterSubmitPostedData += new SaveFormDataEventHandler(FormControl_AfterSubmitPostedData); line, but doesn't trigger. I want to display posted message, and it wont work as shown in example because PostedMessage.Text = this.Translate("/customer/pagetypes/customform/postedmessage"); line resides within mentioned event that doesn't work unless form is set to navigate to some other page.
#15995
Mar 25, 2008 19:07
Vote:
 
Hi. 1. XFormStatistics - what could be the cause of this? Make sure that you have registered the EPiServer.Web.WebControls namespace to your prefix either in web.config or in the header of your aspx/ascx file. 2.AfterSubmitPostedData event doesn't get triggered. If you are using the default template there is already an event handler for this event. This event handler will redirect the page if this has been set up and if this is the case your additional event handler will not be triggered. Just add whatever logic you want in the default event handler if this is the case. If you want to give a message on the same form page then no redirect page should be set up.
#16771
Mar 25, 2008 19:17
Vote:
 
Thanx for the answer. For the first question, I already tried it but will try again. For the second issue it was my bad. I didn't check that the person can submit the form more than once, so the debugger never got into the aftersubmit event. I have another question though: Can XForm support file upload functionality?
#16772
Mar 25, 2008 19:17
Vote:
 
At the moment we do not have built in support for a file upload control for XForms but we are actually investigating it right now so we might have it for the R2 release. For the moment you will have to alter the control collection for the form and add a file upload control yourself.
#16773
Mar 25, 2008 19:17
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.