Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Moshe Recanati 8 posts 89 karma points
    Aug 17, 2017 @ 14:02
    Moshe Recanati
    0

    Extending Umbraco Forms

    We're using Umbraco forms.

    And we would like to extend it with new activities and new types of questions/answers.

    As part of it we would like to listen to next and back buttons and call web services while pressing these buttons. We succeeded to do it for the last submit button by using this code however we couldn't achieve it for back/next buttons.

    Our code below. Appreciate you help.

    Thank you in advance

    Regards, Moshe

    public class RegisterEvents : ApplicationEventHandler {

        protected override void ApplicationStarted(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
        {
            RecordStorage.RecordInserting += RecordStorage_RecordInserting;
            FormStorage.Saved += FormStorage_Saved;
              public void RecordStorage_RecordInserting(object sender, RecordEventArgs e)
         {
            Field item = e.Form.AllFields.FirstOrDefault(x => x.Caption == "חתימה");
            e.Record.RecordData = e.Record.RecordData.Substring(0, e.Record.RecordData.IndexOf(",'" + item.Id)) + "'}";
            e.Form.AllFields.Remove(item);
            return;
        }
    
Please Sign in or register to post replies

Write your reply to:

Draft