web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Issue with variable an...
Power Automate
Answered

Issue with variable and switch function for DocuSign automation

(0) ShareShare
ReportReport
Posted on by

Hello,

 

I have tried to find a way to auto-archive completed envelopes from various units, from DocuSign into specific folders in SharePoint. I have experimented a lot and hopefully, I may have found a way now. However, I am stuck since I cannot establish the correct data to be used with the switch function.

 

Here is what I have done so far:

When an envelope is completed I find the unit number by using Compose 

alessiom2003_3-1662979085479.png

 

Then I have copied a formula from one of my colleagues to be used as variable in the switch function.

alessiom2003_4-1662979189369.png

I have tried to change it to outputs('Compose 2'), but I get an error from Power Automate.

alessiom2003_5-1662979682089.png

When I run the flow with the initial variable: 

int('Compose 2')?['Unit Number']
The flow fails as per below (though, it has recognised the Unit Number successfully.

 

alessiom2003_0-1662978927658.png

alessiom2003_1-1662978968880.png

alessiom2003_2-1662978988432.png

Any idea what I am doing wrong? 

 

Thank you in advance for your help.

Ale

Categories:
I have the same question (0)
  • v-liwei-msft Profile Picture
    on at

    Hi @Anonymous 

     

    You cannot call the current item of a loop outside the loop.

    You should put the switch in the apply to each.

    If you need to use the int function, modify the formula to:

    int(outputs('Compose 2'))

     

    Best Regards,

    Levi

  • Community Power Platform Member Profile Picture
    on at

    Hi Levi,

     

    Thank you for your quick reply. I have tried, but it still gives me an error message.

     

    alessiom2003_1-1663058037896.png

     

    alessiom2003_2-1663058077068.png

    Any idea what I am doing wrong? 

    Thank you

    Ale

     

     

  • v-liwei-msft Profile Picture
    on at

    Hi @Anonymous ,

     

    Could you please provide me with a clearer screenshot of the error report?

     

    Best Regards,

    Levi

  • Verified answer
    v-liwei-msft Profile Picture
    on at

    Hi @Anonymous 

     

    Please modify outputs('Compose 2') to outputs('Compose_2').

     

    Best Regards,

    Levi

  • Community Power Platform Member Profile Picture
    on at

    It works!!!!! 

    Thank you so much!!! Really appreciate your help. You saved me! 

    Ale 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard