context.getEventArgs().preventDefault() Not working for Service Appointments in CRM 2013 RRS feed

  • Question

  • So I have this function:

    var stopSave=function(context) {   
     if (!checkCustomersOk()){
            context.getEventArgs().preventDefault(); //Stops the Save Event    }

    In theory this should prevent the form from being saved and it works fine for updated entities as well as for several non updated entities that I have tried. It's registered on the onSave event and the context is passed as the first parameter

    It does not work for service appointments though.

    There are no errors, it just runs through it and then saves it as if nothing has happened.

    Same behaviour from IE 11 and Chrome 34

    Any ideas?

    Friday, May 9, 2014 6:59 PM

All replies

  • I am having this problem with normal appointments - did you ever get a reply?
    Wednesday, July 23, 2014 10:18 AM
  • I have the same problem and the auto-save creates the entity after running the validation function. Did you find a solution for this problem?
    Thursday, July 24, 2014 6:28 PM