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 / Populate Form based on...
Power Apps
Answered

Populate Form based on Gallery.Selected

(0) ShareShare
ReportReport
Posted on by 32

Hi, all-- I'm trying develop an app for one of our teachers where students can leave feedback for another student. I have a data table which displays the roster, and a form which contains three fields: Student Name, Rating and Comments. I'd like to have the Student Name field populate automatically when the user selects a name off the roster. In other words, when you click "Student #1," that is automatically entered into the Student Name field.

 

The name of the data table is DisplayRoster. The control is RosterNames. In the Student Name data card, I have set Default=RosterNames.Selected. I get an error reading "The Property expects text values, but this rule produces incompatible Record values."

 

Any help is greatly appreciated!

Categories:
I have the same question (0)
  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @jtillinghast

     

    You get the error because RosterNames.Selected is a whole record containing all information about a particular student and not just the name.

     

    To make it work you have to set the Default to:

     

    RosterNames.Selected.DisplayName

    In your case it might not be DisplayName it depends under what column name the student name is.

  • jtillinghast Profile Picture
    32 on at

    Thanks, Martynas-- I changed the Default to RosterNames.Selected.StudentName, where "StudentName" is the name of the appropriate column in the original table. Now I get an "invalid name" error over the box.

  • jtillinghast Profile Picture
    32 on at

    Wonderful! One clarification - I had to set it to DisplayRoster.Selected.StudentName, using the name of the table, not the name of the control. That fixed it, though. Thanks.

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
WarrenBelz Profile Picture

WarrenBelz 358 Most Valuable Professional

#2
11manish Profile Picture

11manish 214 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 185

Last 30 days Overall leaderboard