cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
efialttes
Super User III
Super User III

Set Property WDL function and variables

 

Hi all

I am having problems when using setProperty WDL function in the context of a variable.

 

I am declaring two object variables: "testObject" and "auxObject" via two "Initialize variable" action blocks by assigning the following value:

{}

 

Then, I am setting auxObject value via "Set variable" action block by assigning the following expression:

setProperty(variables('testObject'),'Aditional Info',outputs('Compose_AI'))

 

I can save the flow, and execute it successfully.

The problem arises when I edit the flow, flow editor shows the following error:

 

 ErrorSetVariableEditor.png

It seems once saved and reedited, Flow Editor is understanding the expression as a string instead.

 

So a remove the string, add the expression instead. I can save he flow and execute it successfully. But when I re-edit this flow, the Flow Editor is displaying the error again. I am using Chrome as browser.



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



3 REPLIES 3
v-yamao-msft
Community Support
Community Support

Hi efialttes,

 

Please try to enter the function under Express tab of the Value field.


I assume that the error “Enter a valid json” won’t appear again.


if you are still having the issue, please feel free post back.

 

Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Mabel

Thank you for your fast response.

Your suggestion is what I am doing: I am entering the function under Express tab of the Value field. Then I save and execute the flow successfully (meaning the flow and the expression results are under the expected behaviour).

The problem arises when I re-edit the flow, the screenshot I shared is showing how the action block shows the expression when I press "Edit" whitout any other intervention from my side. So, every time I re-edit, I am forced to re-enter the function under Express tab of the Value field, because for some reason, flow editor shows it as a conventional string.

Can you reproduce the problem?

BR

 

 



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Hi @efialttes,

 

I am not able to reproduce this issue on my side.


To test this issue, I create a flow with the actions “Initialize variable” and “Set variable”, save the flow first, then edit the flow.


When I click the Edit flow button, I don’t get the issue you mentioned. The function in the Value field displays as expected.

3.PNG

 

Which browser are you using? Please try with a different browser to see if it will work. I am using Edge on my side.

 

Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Top Solution Authors
Users online (2,549)