I’m working on CRM 2011 (newbie…) and created a plugin that checks if incidents have activity records. If there are no activity records, the incident cannot be resolved.
I have a custom button launchin a dialog asking few things to the user and then setting the incident status to resolved.
What I would like is for this button to be disabled as long as there are no activity records…
How the hell can I do that??
Thx in advance
I’m not sure this is a rule that can be set for a ribbon button.
These are the rules that you can set on a ribbon button and I can’t see one that allows you to disable based on a related entity count.
I use this when editing any ribbons so i’d maybe have a play with that to see if you can do what you need it to do.
My hunch would be to do a fetch query as the first step in your Dialog, and if that returns a result of 0 ( ie the query finds related activity records ) to end the Dialog.