Last activity: 27 Feb 2018 5:30 EST
Can I evaluate an expression formed as string type in when rule
I have a Parameter of string type set in my Primary page which will contain some set of expression in string format which will be formed dynamically while the code gets executed. So for eg during execution based on some condition i'm setting the parameter to the following value:
Param.SearchCriteria = "@contains(.pyID,RS-239) && @equals(.pzInsKey,RS)"
Now I'm accessing this parameter from a when rule. Is there any such method in Pega using which I can dynamically evaluate the string expression passed to the when rule?
I tried with the following function but it's always returning true which should not be the case :
@CRPDecision.EvaluateExpression(Primary,"@contains(.pyID,239)") -- the SearchCriteria parameter will contain the string "@contains(.pyID,239)" actually.
Please help me out. It's urgent.
Thanks in advance.