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 / Auto Populate Form Fie...
Power Apps
Unanswered

Auto Populate Form Fields with LookUp Field

(0) ShareShare
ReportReport
Posted on by 2

Hello Power Apps wizards!

I'm hoping I can get some direction on how to resolve a formula error I'm getting when trying to auto-populate a form field based on another field.

I have two SharePoint lists: Applicant and Interview Results. The Applicant list contains the names of all applicants along with additional data such as "Location". All of the fields are "single line of text". The Interview Results list contains "Candidate Name" which is a LookUp field connected to "Applicant Name" on the Applicant list. 

 

In Power Apps, I insert an Edit Form on a blank screen and connect it to the Interview Results list. I want the user to be able to select the "Candidate Name" from the drop-down list and then have it auto-populate the "Location" field. I'm using this formula in the Default field: 

 

LookUp('Applicants',ID='Candidate Name_DataCard2','Location')

 

I get this error message: "Incompatible types for comparison. These types can't be compared: Number, Control."

 

I've tried this formulas as well:

 

LookUp('Applicants','Applicant Name'='Candidate Name_DataCard2','Location')

 

The error message adjusts to: "Incompatible types for comparison. These types can't be compared: Text, Control."

 

I suspect the LookUp setting for the "Candidate Name" value on the Interview Results list is causing the issue. However, I must have the "Candidate Name" be a LookUp and be able to record the interview results in SharePoint list. 

 

Any help would be tremendously appreciated!

 

Categories:
I have the same question (0)
  • v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi @malmonkey,

    Do you want to populate the location TextInput based on the Candidate Name selected from the dropdown?

     

    Here is the formula you should try for:

    LookUp('Applicants','Applicant Name'=CandidateName_DataCardValue.Selected.Value,'Location')

    Note that you should refer to the ComboBox control within the Candidate Name data card.

  • malmonkey Profile Picture
    2 on at

    Thanks @v-qiaqi-msft!

    I wasn't referring to the ComboBox control within the Candidate Name data card (and was also entering the formula on the Default property of the overall DataCard , so I've made those changes and have leveraged the corrected statement:

     

    LookUp('Applicants','Applicant Name'=CandidateName_DataCardValue.Selected.Value,'Location')

     

    I'm also entering the formula on the Default property on the DataCareValue item for Location_DataCard. Now I'm getting a different error message - still referring to conflict between Text and Record values:

    malmonkey_0-1651871116756.png

     

     

  • v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi @malmonkey,

    I am confused that if there is a Combo Box within the Candidate Name data card, it should be because the datacardvalue is renamed by default however it is a ComboBox essentially.

     

    Hope I make it clear that if the Candidate Name datacardvalue is the ComboBox essentially, you should reference to the DefaultSelectedItems property instead of the Default property unless you have a Dropdown box.

     

    Another question, the Location field should be from the Applicant list, and you have a form populated with the Interview Results list, how could you populate the location field based on the Candidate Name selected?

     

    Post your form including all the related data cards like Candidate Name and Location, or I could not imagine this.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 536

#2
WarrenBelz Profile Picture

WarrenBelz 426 Most Valuable Professional

#3
Haque Profile Picture

Haque 305

Last 30 days Overall leaderboard