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 / How to Set a default o...
Power Apps
Answered

How to Set a default option when using SharePoint Lookup

(0) ShareShare
ReportReport
Posted on by 1,088

I have a SharePoint list and one column is a lookup.

I have a PowerApp build stand alone (not integrated in SharePoint).

The lookup field works fine, but I would like to set a default option.

I have been able to get the words that I want to show up as the default selected item, but on Submit doesn't populate the SP List.

From reaching looks like I need ID and Value.  Have read several articles:

https://sympmarc.com/2018/02/05/powerapps-setting-a-sharepoint-list-lookup-column/

https://docs.microsoft.com/en-us/microsoft-365/community/working-with-cascading-lists-in-sharepoint-and-powerapps

https://powerusers.microsoft.com/t5/Building-Power-Apps/PowerApps-and-SharePoint-Lookup-Columns/m-p/104177

https://techdailychronicle.com/handling-sharepoint-lookup-and-people-fields-in-powerapps/

https://www.c-sharpcorner.com/article/set-a-default-value-of-the-look-up-column-in-powerapps-new-form/

 

But I'm still not getting it to work?

 

On the combobox I am trying this for the default and defaultselecteditems

{
'@odata.type' : "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
Id: LookUp('Titles and Roles',Title = Office365Users.MyProfileV2().jobTitle,ID),
Value: Office365Users.MyProfileV2().jobTitle
}
 
On the card for update I have tried:
DataCardValue2.Selected
 
And 
{
'@odata.type' : "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
Id: LookUp('Titles and Roles',Title = Office365Users.MyProfileV2().jobTitle,ID),
Value: Office365Users.MyProfileV2().jobTitle
}
 
But neither worked.  No errors, just doesn't add to the list.
 
I dont want to do a patch because I have a flow that runs on create.  So if I did a patch after the create, not sure it would pick it up?
 
Thanks,
Terry
 

 

 

 

Categories:
I have the same question (0)
  • Jeff_Thorpe Profile Picture
    6,085 Super User 2024 Season 1 on at

    Did you verify that the Lookup() is returning the ID as expected? 

  • Mattw112b Profile Picture
    1,088 on at

    I just put it in a Label and it doesn't return anything... not sure what is wrong with it though?  No errors in the console (just a delegation warning), but I won't ever have 2000 items in the list, maybe 60 at most.

  • Verified answer
    Jeff_Thorpe Profile Picture
    6,085 Super User 2024 Season 1 on at

    The delegation warning is because of the Office365Users() call being used in the Lookup. You could put that value from the Office365Users() call in a variable then use the variable in the Lookup and that would resolve the delegation warning. However, if you are under the delegation limit in the 'Titles and Roles' list then you should get a result back even with the delegation warning. Did you verify that the value being returned from Office365Users.MyProfileV2().jobTitle exactly matches a Title of an item in 'Titles and Roles' list?

  • Mattw112b Profile Picture
    1,088 on at

    Geesh.. you are right.. lol  "and" vs "&".

     

    Thanks,

    Terry

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 Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 404

#2
timl Profile Picture

timl 344 Super User 2026 Season 1

#3
WarrenBelz Profile Picture

WarrenBelz 320 Most Valuable Professional

Last 30 days Overall leaderboard