I posted this question before and got no response, maybe the description was vague.
In a project I'm currently working with, we have a Block which contains a XForm property. Now I'm about to fiddle with the AfterSubmitPostedData-event in the Initialization-module for this addon. This step is working fine, the event is executed as expected.
1
2
3
4
public void Initialize(InitializationEngine context)
{
XFormActionHelper.AfterSubmitPostedData += XFormControlOnAfterSubmitPostedData;
}
The problem i face is that i cannot get reference to the block that the XForm lies in. The XFormDataEventArgs doesn't have a reference to the block, just FormData.PageGuid which is of course null. And the sender is null. Is there a way of getting the reference of the block in the event?
1
2
3
4
5
6
7
8
private void XFormControlOnAfterSubmitPostedData(object sender, XFormDataEventArgs e)
{
// e.FormData.PageGuid is null because the form is inside a block
var map = PermanentLinkMapStore.Find(e.FormData.PageGuid) as PermanentContentLinkMap;
..
..
..
}
Hi,
I posted this question before and got no response, maybe the description was vague.
In a project I'm currently working with, we have a Block which contains a XForm property. Now I'm about to fiddle with the AfterSubmitPostedData-event in the Initialization-module for this addon. This step is working fine, the event is executed as expected.
The problem i face is that i cannot get reference to the block that the XForm lies in. The XFormDataEventArgs doesn't have a reference to the block, just FormData.PageGuid which is of course null. And the sender is null. Is there a way of getting the reference of the block in the event?
Thanks for your help