I have started working with the Ribbon Workbench for CRM Dynamics 365 and am having some problems. Specifically, I am need to hide a button if the form in question is Read Only and Active.
I've started by creating a DisplayRule that is assigned to the button in question. The DisplayRule consists of a FormStateRule with the following criteria
Default: False
State: ReadOnly
InvertResult: True
For some reason it isn't working. The button continues to display whether the Form is Read Only or not. Does anyone have any ideas as to how I can get it to work? A requirement this simple shouldn't be this difficult to do!
I should add that I can make the DisplayRule toggle the button in general based on other criteria, it's this exact set of circumstances that I can't figure out.
It turns out the problem was that I was using a DisplayRule instead of an EnableRule. EnableRules provided me with a RecordPrivilegeRules. This provides the ability to determine the rights to the exact record in use as oppose to general access that you would get with a FormStateRule.
I'm a little mad at myself that it took so long to figure out something so simple, but hopefully this will help somebody else down the road.