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 / LOOKUP a value and bri...
Power Apps
Answered

LOOKUP a value and bring information from a table

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi! I made an app that gets info from a sharepoint list. I need to look up the value of the field "Jornada Laboral" in a table and bring the corresponding hours for each month. I first saved the table in OneDrive, the function worked fine for me but not for the people who doesn't have access to the file. Here is the formula I used 

LookUp(Tabla2;Horas=valorJornadaLaboral.Text;Concatenate("2.5";" h"))

To solve that problem, I used the excel connector and uploaded the table "Hours" which is the same table I had in OneDrive, I just renamed it to avoid confusions.

denise_martinca_1-1593028670796.png

 

I used this code 

LookUp(horas;Horas=valorJornadaLaboral.Text;Concatenate("2.5";" h"))

However,  I get this error

denise_martinca_0-1593028449567.png

I don't understand it since it says that the datatype is "Control" and it is invalid although the table is the same, I just bring from an static excel file.

Would you please help me? 

 

Categories:
  • Verified answer
    eka24 Profile Picture
    20,925 on at

    First all Try:

    LookUp(horas;Horas=valorJornadaLaboral.Text;2.5))

    Or

    LookUp(horas;Horas=Value(valorJornadaLaboral.Text);2.5))

    Or

    LookUp(horas;Horas=Value(valorJornadaLaboral.Text);4))

    Am wondering if you can rename the columns

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at
    You're probably getting this warning (not error) because data types are lost between table transfer from OneDrive to Excel. Why don't you pull the data directly from SP List. Why even use OneDrive and Excel?
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    With the last two formulas I get an error, with the first one I get warning however, no results are shown in the screen. The warning says that the values compared in the formula are of different data types so they can´t be evaluated. 

    I changed "Jornada Laboral" type to number (both in the list and in my form) but I still get the same message. I understand that the app detects the type of the field as text because of my formula...

    denise_martinca_0-1593094137790.png

    denise_martinca_1-1593094213039.png

     

     

     

    denise_martinca_1-1593093058107.png

    denise_martinca_2-1593093127751.png

     

     

  • eka24 Profile Picture
    20,925 on at

    If you look at the formulas, I wrapped it with VALUE, but you removed that.

    Recheck the formula again

    LookUp(horas;Horas=Value(valorJornadaLaboral.Text);2.5))

    Or

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I tried the 3 options, that formula gives this error

     

    denise_martinca_3-1593096608104.png

    denise_martinca_4-1593096644777.png

    Than you for your help!

     

     

  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I managed to solve my problem with this code:

     

    LookUp(horas;Horas=Value(valorJornadaLaboral.Text);'2.5')

     

    I had to check all the data types both in my list and the input table of hours. Then I erased the concatenate part of the code since it kept failing. I also added two ' between the 2.5 which also made the function fail

    Thank you all! 

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

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 221 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 188 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 120

Last 30 days Overall leaderboard