Hi all,
Can anyone tell me how can i make my own replacement tag?
For instance a replacement tag like <DataType_1_4_formID_PerformerEmail> that is replaced by the email of the performer of the task?
Thanks!
Hello Ricardo,
Wisteria IT has developed a module that does custom tag replacements as well some other workflow extensions. In short, we created a custom work package to accomplish the task.
If you take a look at $WFMAIN.WAPIPkg.ReplaceVariable method, you will see that, in addition to some of the standard tag replacements, it loops through all of the registered work packages for the workflow and makes a call to each package's GetVariableReplacement method. So, if you create a custom package, you will be able to code your own tag replacements in the GetVariableReplacement method and it will be accessed every time that the WAPIPkg.ReplaceVariable method is called.
Some may write in and tell you that you can patch $WFMAIN.WAPIPkg.ReplaceVariable method and code your tags in that method or another subroutine; which you certainly can do. However, we felt that creating the custom package was a better approach because it did not override core LL/CS code and would be a more supported approach by taking advantage of the work package methods in place to do this work.
If you want to learn how to create a custom package, check the Builder Online Help: Adding New Data Types
I am also attaching our module information to give you some thoughts on how to structure the tags.
Best Regards, Donna