locked
CRM 2011: How to set a Enable Value Rule using the Ribbon Workbench RRS feed

  • Question

  • I want to disabled the activate button for a couple of inactive state-codes, which by default allow the users to reactive the record.  For two of these, I don't want the user to be able to reactive them.  But for any of the others, they need to be able to reactivate them.  I'm not sure how to setup the enable rules for this.

    I have two state-codes, say value 100 and 200, that I want to disabled the activate button for, but everything else I want it enabled.  How would I set that up as an enabled rule?

    I have tried to setup an enable rule for the 100 and another enable rule for the 200, and invert the results on each. That doesn't work. It disables the activate button for everything. I have tried to setup an OrGroup with the same two value rules and that also doesn't work. So I am not sure how you would set this up.

    It seems easy, but doesn't work for me.  I think I might be misunderstanding something simple here.  I did read that inverting the results works like.

          return statecode != 100

    versus not inverting would be:

         return statecode = 100

    Is this correct?  That is NOT inverting the result, but just the comparison operator.  So if I nested two of these, it would not work for me.  So I need something like.

    if (statecode != 100 and statecode != 200) { 
       return true;  
    } else { 
      return false;
    }

    Or it would work by inverting the logic:

    if (statecode = 100 OR statecode = 200) return false;

    So how would I set that up as an enable rule?  Would not just to enable rules as follows work

    1. Value Rule: Field=statecode, InvertResult=True, Value=100

    2. Value Rule: Field=statecode, InsertResult=True, Value=200


    Jon Gregory Rothlander




    Thursday, August 6, 2015 8:44 PM

All replies

  • You can try Display Rule to hide a button.

    Or validate other conditions which are currently bound with currently attached enable rule, it might conflict with your rule.


    Friday, August 7, 2015 4:45 AM