Hello,
I have a development requirement for D365 F&O on the SalesCreateOrder form. When order entry occurs, they would like to enforce that the same customer account (SalesTable.Custaccount) does not use the same customer requisition (SalesTable.PurchOrderFormNum) in the system. My solution is to have a formDataFieldEventHandler on the PurchOrderFormNum and check for duplicates OnValidating. This works fine, but it does not enforce the duplicate from being written. I can do the same thing on FormDataSourceEventHandler, OnValidatingWrite but again, it's not enforcing the write. I was about to create a table extension with an index to enforce the uniqueness on Custaccount and PurchOrderFormNum, but Microsoft warns this will not be supported in future releases.
What can I do to enforce that the form will not allow the write?
Thanks,
Steve