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 / Collect function in Po...
Power Apps
Answered

Collect function in PowerApps not populating data in lookup field in SharePoint list

(0) ShareShare
ReportReport
Posted on by 4

Hi potential question answerer,

 

I'm building a Power App that has a gallery of "Issues". When you select an item my "frmIssues" goes into update mode via "varCurrentIssue" variable. I want to attach some referential data to this Issue item but I'm getting some strange behaviour..

 

I have a "BugCreator" SharePoint list I want to link to the "Issues" SharePoint list:

columns.PNG

 

I have a button that that creates some data in the BugCreator list that should tie back to the Issue:

 

Collect(BugCreator, {Title:"Bug: " & varCurrentIssue.Title, StoryPoints:5, IssueTrackerItem:varCurrentIssue});
Set(varStatus, "Bug Created");
SubmitForm(frmIssue);
ResetForm(frmIssue);

 

 

The problem is the Title is there and looks good:
Title: "Bug: A New problem",

StoryPoints: 5,

IssueTrackerItem: !Required Info

 

Why is there no data in only the lookup column?

problem.PNG
function.PNG
columns.PNG
Categories:
I have the same question (0)
  • Verified answer
    mdevaney Profile Picture
    29,991 Moderator on at

    @Shaunus 

    The LookUp column requires a special structure.  I am assuming varCurrent issue doesn’t contain something that looks like this:

     

    {
     '@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
     Id: 1,
     Value: "Text Description"
    }

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

  • Shaunus Profile Picture
    4 on at

    @mdevaney  Thanks for the quick reply 😁

     

    You've solved it in one! 

    I couldn't work out why it would accept the type but wouldn't link it SP side.. I did see that syntax but couldn't for the life of me figure out how to get it to compile until you laid it out for a 5 year old.

     

    I normally work with C# - feel like a right idiot now 😅

     

    Thanks again, much appreciated!

  • mdevaney Profile Picture
    29,991 Moderator on at

    @Shaunus 

    Anytime man!  Best of luck building your app.

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

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 551

#2
WarrenBelz Profile Picture

WarrenBelz 430 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 298

Last 30 days Overall leaderboard