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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Apps
Unanswered

Variables in Flow

(0) ShareShare
ReportReport
Posted on by

Is it possible to declare variables with any function or code in Flow manually and reference to them later in PowerApps?

 

The only known possibility for me is to use the Ask in PowerApps function. This is very confusing if you are using more as 100 in one single flow. Additionaly you need to keep the order from the first to the last variable.

 

 

Categories:
I have the same question (0)
  • Pstork1 Profile Picture
    69,599 Most Valuable Professional on at

    If you are talking about declaring variables when calling a flow from Power apps then take a look at the Power Apps V2 trigger.  With that trigger you can create all the parameters in the trigger and won't need to use Ask in Power Apps.  However you will still need to add them in the order that they are declared.  When sending a large number of parameters to a flow I normally add them all to a record or a collection in Power Apps and then send that as a single string to the flow using the JSON() function.  That string can then be parsed in the flow using the Parse Json action to get the individual parameters.

  • maskwer Profile Picture
    53 on at

    Unfortunately the v2 trigger is limited to 19 variables only.

    There is some workaround with JSON, but I think with the standard trigger and Ask in PowerApps it's still faster.

     

    Thank you.

  • Pstork1 Profile Picture
    69,599 Most Valuable Professional on at

    The problem is that when you get that many parameters, with either trigger, its almost unusable in the Power App.  As you mentioned the parameters need to be entered in order and the intellisense prompting in the Power App gets cut off after the first couple parameters.  I've seen lots of issue with errors because the wrong values are in the wrong place in the parameter list.  Send the values as a JSON string gives all the values a key name so the order no longer matters.  You can change the layout of the record/collection at any time and as long as you update the schema in the flow it will continue to work.  If you have that many parameters I really suggest you look into sending them as JSON. 

     

    Also, the V2 trigger is no slower than the V1 trigger if the parameters are correct.  Its just a difference in the way the parameters are defined.  The V2 version is much easier to maintain.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 335 Most Valuable Professional

#2
11manish Profile Picture

11manish 165

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 96 Super User 2026 Season 1

Last 30 days Overall leaderboard