ProcessFlow: How to call a flow from another flow?

 12 Replies
 1 Subscribed to this topic
 52 Subscribed to this forum
Sort:
Author
Messages
Jose Gonzo
Basic Member
Posts: 20
Basic Member
    Is it possible to call a flow from another flow?

    I have a process that changes several forms; I was planning to create a flow for every form and a Main flow that called the 'form flows'? If not possible, any suggestions on how to accomplish something like that?

    I have checked the forum but couldn't find an answer

    Thanks for all your help. Have a great day.
    BarbR
    Veteran Member
    Posts: 306
    Veteran Member
      Absolutely, I have a similar flow that triggers other flows. They key is that you need to create a PF Service for the flows you want to trigger, and then you trigger the Service using the WorkObject node.
      John Henley
      Posts: 3353
        It's actually very easy to nest flows. Use the "Custom Activity" node, with the Activity called "FlowRunner".
        Thanks for using the LawsonGuru.com forums!
        John
        Jose Gonzo
        Basic Member
        Posts: 20
        Basic Member
          Thank you all.

          I am trying to use the CustomActivity node with the FlowRunner Activity. I have set the Action to "runFlow", but when I try to set the "Input" properties (using the Set button or 'double-clicking' I get a pop dialog that says 'Set input property values' and list the name and type of the property, but doesn't allow me to change it.

          Questions:

          1. How do I set the Input properties?
          2. Do you have any samples of how to use the CustomActivity node with the FlowRunner Activity?

          I am using the "ProcessFlow Designer" version 9.0.1.9678. The Lawson "ProcessFlow Developer Guide", Version 9.0.1.x, Published November 2008 only lists the properties of the node, but doesn't provide any examples.

          Thank you for all your help. Have a great day. Cheers.
          Jose Gonzo
          Basic Member
          Posts: 20
          Basic Member
            I reported the issue to Lawson. There is a bug on the ProcessFlow Designer (Eclipse version) that doesn't allow to change the properties on a CustomActivity node with a FlowRunner Activity (JT 340410). The Designer (classic version) doesn't have the issue.

            Thanks for all your help. Happy Friday. Cheers.
            scharby
            Basic Member
            Posts: 5
            Basic Member
              I'm also interested in using FlowRunner.  I was able to enter input values.  The first time use click on the 'Set values' button, nothing happens.  Do it a second time and you do get the input dialog box.  John Henley, you knew of FlowRunner, can you tell us anything more about it? or point us to some kind of info.  Thanks...
              Jose Gonzo
              Basic Member
              Posts: 20
              Basic Member
                Did you find any info? I've been searching the Lawson KB with no luck...it is useless, as the Lawson documentation. Thanks for all your help. Have a great day.
                Jose Gonzo
                Basic Member
                Posts: 20
                Basic Member
                  Got it to work with the help of Lawson support. Two things to make it work:

                  1. Copy the 'nested' flows (xml files) to the server's %LAWDIR/bpm/pfrepository directory.
                  2. On the Run Options, select Run on Server.

                  IMPORTANT: if your flow 'logs' to a file, the directory structure and log file need to exists on the Server.

                  The WorkUnit log files can help troubleshooting. They are located on the server's %LAWDIR%/bpm/wflog. You can also check the CustomActivity output variables after calling the 'nested' flow (_flowErrorCode, _flowErrorMessage and _flowReturnMessage).

                  Hope this helps. Thanks for all your help.
                  Terry P
                  Veteran Member
                  Posts: 234
                  Veteran Member
                    Regarding the ability to enter the property values. When the pop-up window opens, you have to hover your cursor in the lower right corner of the box until it becomes a double-ended arrow - then click and drag the box to make it bigger. When you do the Value field is now displayed and ready to enter values in.
                    Terry P
                    Veteran Member
                    Posts: 234
                    Veteran Member
                      There is little to no documentation I have found of an example of what the Input Values should be set to for FlowRunner. Can someone post an example of which fields need values? Thanks

                      Terry P
                      Veteran Member
                      Posts: 234
                      Veteran Member
                        Anyone have an example of using Flowrunner to call another Flow?
                        Terry P
                        Veteran Member
                        Posts: 234
                        Veteran Member
                          Still looking for information on the Flowrunner activity of CustomActivity. I can't figure out using this or the WorkObject how to "wait" unil the called service completes before resuming. Anywhere documented what values the Java Bean Input field values are used for?
                          Peter O
                          Veteran Member
                          Posts: 69
                          Veteran Member

                            Hi Terry,

                             

                            We don't use the flow runner via custom activity, we instead use the Trigger node introduced for IPA (not PFI?), which essentially appears to be a builtin flowrunner

                            The custom activity node is "documented" in the latest "Infor ProcessDesigner Help" documentation on pg 45.

                            There's some pretty detailed examples of how to use custom triggers on page 173 which can be related to how to call custom activity nodes, similar logic should apply.

                            looking at the screenshot you posted in previously, those fields seem to be pretty clear for their intent-

                            flowCreateWorkunit : true #-- create a workunit or not

                            flowDataArea : yourDataArea #-- maybe your < !approdline >

                            flowInputData : YourJBean #-- trigger documentation has some similars ideas for integrating your Jbeans, and might be helpful

                            flowName : YourFlowName

                            flowSyncExecution : true # if you want it to run in sync (often for grabbing a return variable) , false if you want to run it Async (runs wild)

                            service: TheServiceName # build the service in landmark and set this variable to the name of the service you want to call. 

                            -----------------

                            All this being said, the trigger node seems alot clearer to me.

                             

                            ~Peter