You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Can't pass variable text into a template for use in a Planning expression

Received Response
edited Jun 19, 2023 8:28PM in Planning 12 comments


I have a groovy rule that executes a calc that references a Template. Here is a snippet:

String ApproverMsg = '"' + "This is a Test" + '"'

Calc ="""

In the Template referenced, I use a design time prompt (of type string passed in from the rule above) in a Planning expression like so:

"Approver" = [[PlanningFunctions.getIdForString([ApproveMsg])]];

Unfortunately it throws an error on execution. If however I hardcode the DTP in the Template call instead of using a variable it works fine:

 Calc ="""
     "ApproveMsg":=[["This is a Test"]]

Howdy, Stranger!

Log In

To view full details, sign in.


Don't have an account? Click here to get started!