Include variables from text

  • 21 August 2019
  • 3 replies
  • 4 views

Hello,

I am trying to generate notifications from a workflow dynamically. I can easily generate a message from SQL Procedure based on parameters. But where I am having issues is including Workflow variables in these messages. Is there a way to do this ? Is there a text representation of a variable? What I want to do is to write something along the lines of {Workflow.RequestID} and have it be replaced by the RequestID variable. Is this possible in K2 Five? 

 

Thank you 

Tom 


3 replies

Badge +8
Notification using send email yes there is, go to control Message, then go to properties (right side of the screen), go to context browser. Go to TAB workflow or use any of the environment variable. I used it and it works. I hope I understand it correctly.

Cheers.

That certainly works, but it is not what I need to do unfortunately. I want to generate the messages remotely, as they are dependant on many factors (Such as different groups of customers want different notifications for same tasks) and manually putting them in would take a lot of time and make the WF messy. So ideally what I would do in a WF is just call a SMO method that returns message based on parameters from SQL. Problem is that I don't know if it's possible to somehow refer to variables through say HTML or something.

Badge +8
Your idea is great.
Yes, you can define a local variable from the WF and use it to received a return value from SMO. The same variable to use in your HTML format.
Another option is to use the SMO inside your mail, it works too.

Hope it helps one way or another.

Regards

Reply