Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Unanswered

ClearCollect and Filter from a lookup column from Dataverse and Selected Gallery

(1) ShareShare
ReportReport
Posted on by 6
Hello, so I have this code here which gives me incompatible types for comparison. 
 
I wonder if there's a way to convert the type to match the text in the gallery selected.
 
 
ClearCollect(
    Project_Collection,
    Filter(
        'Projects Hazard Assessments',
        Project_Lookup = Information_Gallery.Selected.Value
    )
)
 
Categories:
  • Paul DC Profile Picture
    6 on at
    ClearCollect and Filter from a lookup column from Dataverse and Selected Gallery
    Hi @FLMike
     
    Project Lookup is a LookUp column in Dataverse.
     
    Column type is just a text field. All I have for now were just simple text fields.
     
    I somehow made it work with this code:
     
    ClearCollect(
        ProjectCollection,
        'Projects Hazard Assessments',
        Filter(
            'Projects Hazard Assessments',
            Project_Lookup.'Project Title' = Information_Gallery.Selected.'Project Title'
        )
    )
     
    What concerns me now is whenever I select a gallery it shows up the data on my table with 2 rows of text fields.
    And what I wanted to happen is to appear the first row of fields and able to input the Hazard Assessment
    because on this scenario I just inputted the data through my table.
  • Suggested answer
    Michael E. Gernaey Profile Picture
    41,306 Super User 2025 Season 1 on at
    ClearCollect and Filter from a lookup column from Dataverse and Selected Gallery
    Hi
     

    What it the Column Type and what field type is it bound too in your Gallery. Did you Type Value, or was it the only property on the .Selected?
     
    So, atm no idea if it can be converted because I dont know what it is. So not sure what to convert it to.

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,670 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,004 Most Valuable Professional

Leaderboard