question

Peter-7064 avatar image
0 Votes"
Peter-7064 asked MayankBargali-MSFT commented

Workflow Validation Error with Invoke a workflow action

I'm using the 'Invoke a work in this workflow app' action in my workflow, so that I can kick off another logic app.

143213-image.png


When I try to set the name of the workflow to invoke in the 'workflow name' parameter using a variable like so:

143178-image.png

I get the following error when saving:

143177-image.png


The only thing that seems to work is using the in built drop down option however I need to be able to set it from a variable which is retrieved from a previous action dynamically and it can change.

Is this a known bug or am I missing something here?


azure-logic-apps
image.png (4.3 KiB)
image.png (10.8 KiB)
image.png (9.6 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

MayankBargali-MSFT avatar image
0 Votes"
MayankBargali-MSFT answered MayankBargali-MSFT commented

@Peter-7064 AFAIK the validation is the same as you enter the workflow name while we create a new workflow. So the workflow name doesn't support the character such as '@', single quotes, braces, etc.

In the code view, it creates the below code and id parameter cannot have unsupported character as we can see @variables(test)

 "Invoke_a_workflow_in_this_workflow_app": {
                 "inputs": {
                     "host": {
                         "workflow": {
                             "id": "@variables('test')"
                         }
                     }
                 },
                 "runAfter": {
                     "Initialize_variable": [
                         "Succeeded"
                     ]
                 },
                 "type": "Workflow"
             }

I have reached out to my team to confirm my understanding and I will keep you posted.

Update 10/26:
I have got confirmation from my product team that dynamically determining the workflow name is not supported. In case if you have HTTP workflow you can call your HTTP trigger workflow using HTTP connector.

· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Ye I suspected it wasn't supported. It would make it easier to deploy the template to multiple environments if you could by simply reference the app name though.
In any case I had already used the HTTP connector as the work around.

Cheers.

1 Vote 1 ·

@Peter-7064 Thanks for your response. I have passed the feedback to the team and due to the limitation, it is not supported.
Just in case for the community if you don't want to call it directly using HTTP, you can also set up a condition and X number of branches with workflow actions that have the respective workflow selected. This will work best when your X is a low number so that you can still take advantage of using the native action to call the workflow rather than HTTP.

0 Votes 0 ·