Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Building Power Apps
Suggested answer

Gallery text return two values with lookup

(1) ShareShare
ReportReport
Posted on by 4
I have an issue using lookup to translate from data source file
 
LookUp(Translation,key="item" And Title=setLang,Value)
 
the issue is that the lookup return with two value while there is only one value in the data source file.
 
and if I use thisitem.item it only shows the correct value.
 
I am trying to translate the full page but the issue with gallery that return two values
 
 
Categories:
  • Suggested answer
    SaiRT14 Profile Picture
    1,961 Super User 2025 Season 1 on at
    Gallery text return two values with lookup
    Pls check the following:
     
    • The issue might be due to the logical conditions (key="item" And Title=setLang).
      • LookUp(Translation, key = "item" && Title = setLang, Value)
    • Even if you expect only one value in the data source, there might be duplicate entries for the same key and Title in the Translation table.
    • If you're using this inside a Gallery and it’s returning multiple values, it may be because the Gallery context (such as ThisItem.item) is conflicting with the LookUp function.
      • LookUp(Translation, key = ThisItem.item && Title = setLang, Value)
         
    • If there are still multiple matches and you only need the first match, you can wrap the LookUp in a First() function
      • First(LookUp(Translation, key = "item" && Title = setLang, Value)).Value
         
    • Use a Label control to display the results of your LookUp function temporarily
      • Text(LookUp(Translation, key = "item" && Title = setLang, Value))
    try out ping me if you require more details.
  • Nandit Profile Picture
    1,563 Super User 2025 Season 1 on at
    Gallery text return two values with lookup
     
    Can you share how you have things up for translation and what are you trying to translate? 
     
    Kind regards,
    Nandit
  • timl Profile Picture
    34,935 Super User 2025 Season 1 on at
    Gallery text return two values with lookup
    Where in your app are you calling LookUp?
     
    The property that controls the items that are shown in a gallery is the Items property. This property expects a Table and it's this formula that results in the 2 items that are shown in your gallery. Therefore can you confirm the formula that you've used here? 
  • AG-21101159-0 Profile Picture
    4 on at
    Gallery text return two values with lookup
    I tried both but it did not work for me
  • Suggested answer
    Nandit Profile Picture
    1,563 Super User 2025 Season 1 on at
    Gallery text return two values with lookup
     
    Can you try using the following please:
    LookUp(Translation,key="item" And Title=setLang)
    
    Or if you are trying to get a value from a specific column, you could use the following:
    LookUp(Translation,key="item" And Title=setLang).ColumnName
    
    If this doesn't work I would suggest you share how you have things up for translation and what are you trying to translate? What do you mean by translating the whole page?
     
    Kind regards, 
    Nandit
     
    If this answers your query, please mark this response as the answer.
    If its helpful, please leave a like. Thanks!
     

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

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,618 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,962 Most Valuable Professional

Leaderboard