Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

CRM 365 Behaviour of the save button.

Posted on by

Hello ALL Experts,

I need to know is it default behavior of CRM 365 that ,

I have Business Process Flow on custom entity having different stages ,

when i click on Next Stage button , the bottom right corner button seems to be automatically saving.

My query :-

when we click on Next Stage the save button automatically saves it, what actually it's doing , is it saving the whole form  again, or something else happening there.

if it's saving the whole form again then one custom JavaScript code has been written on form save which does the updation of the field on the with stage name.

*This post is locked for comments

  • Suggested answer
    Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: CRM 365 Behaviour of the save button.

    Hi,

    If it is to tedious to achieve it with Javascript, you could also implement a plugin running on the update of the "stage name" field.

  • Verified answer
    Alex Fun Wei Jie Profile Picture
    Alex Fun Wei Jie 33,626 on at
    RE: CRM 365 Behaviour of the save button.

    Hi,

    you need register the function under onload.

  • EmployeeOcta Profile Picture
    EmployeeOcta on at
    RE: CRM 365 Behaviour of the save button.

    Hello Experts,

    for which event handler do i need to register the function.

    can anyone help me in that.

  • Suggested answer
    Alex Fun Wei Jie Profile Picture
    Alex Fun Wei Jie 33,626 on at
    RE: CRM 365 Behaviour of the save button.

    Hi,

    or if you do not want to go for Javascript, you can create a workflow to do that ( make sure you apply enough checking before update the record, such as stage id or stage name). you can refer to the below article to see how to implement a workflow inside a BPF

    alexmscrm.blogspot.my/.../dynamics-365-workflow-within-business.html

  • Suggested answer
    Syed Ibrahim Profile Picture
    Syed Ibrahim 6,257 on at
    RE: CRM 365 Behaviour of the save button.

    yes as jie suggested, you register your JS on stage change. Pls use the below code

    formContext.data.process.addOnStageChange(myFunction);

    Reference:docs.microsoft.com/.../addonstagechange

  • Suggested answer
    Alex Fun Wei Jie Profile Picture
    Alex Fun Wei Jie 33,626 on at
    RE: CRM 365 Behaviour of the save button.

    Hi,

    you need change your javascript to trigger when stage change , more information please refer to below post.

    msdn.microsoft.com/.../dn817878.aspx

  • EmployeeOcta Profile Picture
    EmployeeOcta on at
    RE: CRM 365 Behaviour of the save button.

    Hello Experts,

    After change of the Next Stage i want the form to be saved.

    there is one JavaScript which is written on form load and save for both.

    that JavaScript code tries to set the value to a field on the form which is in hidden section to the stage name.

    Now when click on Next Stage the bottom right corner save button changes to saving that means the form is getting saved.

    if it's getting saved then the value in the text field also be saved, but unfortunately it doesn't.

    when we refresh form it shows unsaved changes.

    so i want explicitly the form should be saved with the change in the value.

    any help will be appreciable.

  • Suggested answer
    Syed Ibrahim Profile Picture
    Syed Ibrahim 6,257 on at
    RE: CRM 365 Behaviour of the save button.

    yes it the behavior . Even though if you turn off the auto save for all form from System Settings, upon click on "Next Stage" if the form is dirty it will save the form upon moving to next stage.

    just try the below js on the form.

    https://community.dynamics.com/crm/b/1984crm/archive/2016/12/07/disable-auto-save-on-only-one-form

    Hope this helps. Pls mark it as Answered/Verified to close the thread if suggestion resolved your query

  • EmployeeOcta Profile Picture
    EmployeeOcta on at
    RE: CRM 365 Behaviour of the save button.

    Hello Aric,

    i want to explicitly save the form fields when i click on Next Stage ,

    is it possible to do that.

  • Verified answer
    Aric Levin Profile Picture
    Aric Levin 30,188 on at
    RE: CRM 365 Behaviour of the save button.

    Hi,

    The Save operation that happens in the background (AutoSave), only saved the fields that were changed since the last save, not everything. If you did not make changes but moved stages, it is likely that some system fields (such as stage for example) got dirty, which is what is causing the form to save.

    Hope this helps.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans