Question:
I am having difficulty getting the data from 1 step of my workflow into the next step's work item text i.e. using text and inserting a variable as an expression. I have tried using &_WI_OBJECT_ID& and various other combinations of expressions from the container list. This situation is further complicated in that the step that has just been invoked via the previous method is a custom transaction that I have previously written.
I have managed to get the data back from this transaction via exporting to database indx(zz). N.B. Export to memory id does not seem to work going back from my custom transaction to the next method in the w/flow.
Any ideas why I can't get data into the work item text?
Answer:
Hi,
It seems to me that your problems stem from a bad workflow design.
Using the export/import technique to pass parameters from a method to a custom transaction is fine in my view, but the alarm bells ring when you talk about using database indexes to pass the data back.
Now, you don't mention what this custom transaction of yours actually does, but, if it's supposed to pass data back to the workflow, it sounds like it's anything but a display task. In which case, your task to call the transaction should be asynchronous with a terminating event raised in your transaction code, invoked when the user completes whatever the transaction requires.
Once you've got this framework in place, you can populate the terminating event container with whatever parameters you wish, then bind them back to your task container, then back to your workflow container.
This is far better design, and, I suspect, will be much easier to maintain.
As far as your workitem text variable goes, you should be able to define the text in your transaction (if that's what it's contingent on), put it in the event container, send that back to the workitem container via the bindings, then use it in your next activity step.
I don't think that container element '_WI_OBJECT_ID' is what you want in the workitem text. This is quite a lengthy structure, which doesn't particularly seem appropriate in any context.
Regards,
Tim
Answer:
Thanks very much for your help.