Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Answered

How to add a customized validation in Save button in VendEditInvoice form in D365 FO

(1) ShareShare
ReportReport
Posted on by

Hi Everyone,

Is it possible to add a custom validation whenever a user will click the save button of VendEditInvoice form? I have tried already to create event handler class on some part of the form, like the validateWrite() of the datasource but it doesn't satisfied some of the requirements. I really need to put it to Save. 

screenshot-save-button.PNG

Hope you someone can help me on this

Thanks in advance!

  • CU23010927-0 Profile Picture
    CU23010927-0 on at
    How to add a customized validation in Save button in VendEditInvoice form in D365 FO
    Hi  knives1991,
    I am looking for the same solution. Can You explain how you did it?
     
  • knives1991 Profile Picture
    knives1991 on at
    RE: How to add a customized validation in Save button in VendEditInvoice form in D365 FO

    Hi Martin, Thank you for your input.

    Understood your point and that make sense. I have found a workaround on this and changed some of the design.

  • Verified answer
    WillWU Profile Picture
    WillWU on at
    RE: How to add a customized validation in Save button in VendEditInvoice form in D365 FO

    Hi knives1991,

    Agree with Martin, you should not put your code on the button.

    What are your actual requirements? If you want to validate a field on the form, you could create try the validataField eventhandler on the table.

  • Verified answer
    Martin Dráb Profile Picture
    Martin Dráb Most Valuable Professional on at
    RE: How to add a customized validation in Save button in VendEditInvoice form in D365 FO

    I'm afraid we want be able to design a solution that satisfies your requirements if you don't tell us what the requirements are.

    As far as I know, all what the button does is saving the data source. If it's not what you want, maybe you need to re-think your design.

    By the way, do you realize that there are other ways of saving the data besides clicking the button? For example, I can press Alt+S or close the form. If you put your logic on the button, it won't work in all cases.

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

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey Pt 2

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa

Leaderboard

Product updates

Dynamics 365 release plans