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 / Form Data source error...
Power Apps
Unanswered

Form Data source errors when selecting an item from a gallery

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

I have a function querying certain fields in my app to select a specific sharepoint list. The data is then collected and the collection displayed in a gallery. The gallery leads to a 3rd page where a specific item chosen from the gallery is to be shown in a form. The 'Item' field in this form is set to GalleryName.Selected. I do however have an error on the form 'Item' field as follows:

 

Invalid Formula. Expected value with compatible 'DataSource'.

 

This worked perfectly until recently. And I can't find the issue. Is there some update on sharepoint that was made.

If I set the item selected as a variable, the entire record is captured, but I cant display it in the form.

 

 

 

Categories:
I have the same question (0)
  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at

    Hi @Anonymous 

     

    Can you please confirm the Data Source that you are using? I am guessing that is because you have used an invalid data source on your edit form.
     
    Hope this Helps!
     
    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    It is a SharePoint list

  • yashag2255 Profile Picture
    24,769 Super User 2024 Season 1 on at

    Hi @Anonymous 

     

    Please make sure that you Gallery control and Edit form have the same data source, i.e. they both are pointing to same SP list. 
    I carried out a test on my side and this error popped up when data sources are different on both the controls.
     
    If you are using the same SP list, then make sure that the items property of gallery and  Data Source of Edit Form have the same attributes selected in the controls. If you need more clarity on this, please share the expression on items property of your gallery control and DataSource of the Edit Form.
     
    Hope this Helps!

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    So here is the thing. My function dynamically choses a datasource, and then collects the results. The collection is displayed in my gallery, and when I select an item from the gallery, the app wants to use a datasource to get the information, instead of my collection.

     

    As i mentioned this worked until a few weeks ago. So i can't see what the problem is.

     

    So I have various lists, lets call them A, B and C.

    Based on certain inputs, a collection is made of either list A, B or C. The information is collected perfectly. Now I display the collection, 'SearchResults', in my gallery. 

    1.JPG

    When I select the item, it takes me to a new page with a form having the following properties:

    Item - SearchGallery1.Selected, which provides the following error:

    "Invalid Formula. Expected a value compatible with 'DataSource'.

     

    So the form wants to choose a datasource, but has to choose the collection as its source.

     

     

     

     

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

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 846

#2
Valantis Profile Picture

Valantis 532

#3
Haque Profile Picture

Haque 410

Last 30 days Overall leaderboard