Power Platform Tip #23

Your business rule does not run on the record your flow writes

Entity scope runs a business rule on the server as a synchronous plug-in; any other scope runs it as client-side JavaScript, so a write that never opens the form never runs it.

You write a rule that shows an error when priority is empty, and on the form it does. Then a flow creates the record with priority empty, and the rule has nothing to say about it.

Scope is the setting that decides where the rule runs, and it reads like a question about which form to put it on. Entity runs the rule on the model-driven app forms and on the server, All Forms runs it on the forms only, and a named form runs it on that one form. The server run is the rule generated as a synchronous plug-in; the form run is JavaScript on the client, and a write that never opens the form never runs it.

To hold a validation on a record written away from the form:

  1. Deactivate the rule. It cannot be edited while it is active.
  2. Set Scope to Entity.
  3. Save it, then select it in Solution Explorer and activate it there. The designer has no activate.
  4. If it also sets a requirement level, hides or disables a column, or carries a recommendation, those actions only apply to form-scope rules, so give them a rule of their own and leave that one on a form.

Then write the record from the flow and watch whether the rule catches it.

A rule that does not fire on the form at all is a different fault: check that every column the rule names, in a condition or an action, is on that form.