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 Platform Community / Forums / Power Apps / column name as variable
Power Apps
Answered

column name as variable

(0) ShareShare
ReportReport
Posted on by 5

Hi,

 

i have an App with a dataset (connected to an Excel Table) with 20 columns (named e.g. col1, ..., col20) and i defined a variable holding a column name (e.g. UpdateContext({selCol:"col5"}). Is there a way to extract the column from the dataset with the name in the variable (selCol in the example) and assign it to a collection?

 

thanks.

Categories:
  • Verified answer
    WarrenBelz Profile Picture
    156,526 Most Valuable Professional on at

    Hi @juraj_katriak ,

    No unfortunately, you cannot refer to column names dynamically - you would need to hard-code it all.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

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 July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 402 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 296 Most Valuable Professional

Last 30 days Overall leaderboard