November Happy Hour will be moved to Thursday December 5th.
AI OnAI Off
November Happy Hour will be moved to Thursday December 5th.
In your view, how are you adding the XForm? I believe there's an overload to the method where you can pass in some parameters for this.
Frederik
The view looks like this:
@Html.DisplayFor(m => m.XForm, new { XFormParameters = new XFormParameters() { SuccessAction = "Success", FailedAction = "Failed"} })
Hi,
Any answeres on your question? Did you solve it?
I would be grateful if you posted your solution.
We´re using XForms on our EPiServer 7 + MVC site. On our XFormPage we´re trying to read and modify what ChannelOptions the form should use by subscribing to the BeforeSubmitPostedData event. The event fires alright, but the ChannelOptions is always None when trying to read it. Are we doing anything wrong here?
public class XFormPageController : PageController<XFormPage>
{
public ActionResult Index(XFormPage currentPage)
{
XFormActionHelper.BeforeSubmitPostedData += OnBeforeSubmitPostedData;
return View(currentPage);
}
private void OnBeforeSubmitPostedData(object sender, XFormDataEventArgs e)
{
// e.FormData.ChannelOptions is always None
}
}